Developing on localhost

Why

For developers is practical to develop experiments on a local web server while developing them. Although using Convert QA audiences this is not necessary, some people prefer this method of development. 

How

Convert has no issues if you install its tracking code on pages on a web server installed on local machine. However, you need a fully qualified domain name as a domain like "localhost" or "mymachine" wont work. A fully qualified domain is required for the tracking script to run and write the required cookies it uses to function. 

Even if you don't own, or have control of a domain and it's DNS settings you can use whatever qualified domain you like as "domain.com", "mymachine.com", etc. 

The way to do it is to edit the "hosts" file of your machine and put an entry to point to your own IP address.

Example:

domain.com   127.0.0.1

127.0.0.1 usually stands as an alias for your own machine. So it is safe to use it.

Be sure that the domain matches your project settings active websites and your site area settings. Also, make sure your goals URL settings also can be matched.

If you are using the local machine as a dev machine, make sure you choose a different domain than the one used on your site, to prevent launching experiments on your live site in your same project.

Have more questions? Submit a request

Comments