I started to develop my own wordpress site, that I hosted locally. I am using Apache for hosting and mariaDB for DB. I accessed the site through my public ip, that in my case was was xxx.xxx.1.163. I could also access my site thorugh I set the wordpress site up and everything worked fine.


Until I moved from one place to another with my computer. Now I can not access my site anymore. I have been struggling with the problem for 2 days now. Now my public ip is xxx.xxx.1.110. Problems that occur, when I try to access site:

Accsessing through browser

  • When i try to access through, then it automatically redirects me to xxx.xxx.1.163, although I have erased all the Firefox cache, history and cookies.

  • When i try to access through xxx.xxx.1.110, then it also redirects me to xxx.xxx.1.163

I have tried the same in Chrome also. Results are the same.

What I have tried and outlined:

Apache working fine - When I have only apache's index.html file in /var/www/html directory, then I am able to access the default Apache page through and through my current public ip xxx.xxx.1.110. Like this everything seems fine.

Original wordpress - When I move original wordpress files to /var/www/html directory, then then from and xxx.xxx.1.110 the wordpress first setup page appears. Like this everything seems also to be fine.

When I try to set up the wordpress, with the same database connection that i had the last one, then it thorws error and says "Wordpress already installed". And now, when I try to connect to or xxx.xxx.1.110 then it automatically redirects me to my old public ip xxx.xxx.1.163

When I move my own wordpress project(the project that I had before and was working) to the /var/www/html folder, then the same thing happens. I keep getting redirected to xxx.xxx.1.163


My idea is that i would probably have to make some changes in my wordpress database and maybe in my wordpress conf files. But I have no idea where I should change and what I should change. I have looked it up also but I have found very different answers.

If somebody could tell me, if I am moving in correct direction or what exactly should I change, then I would be very thankful.

  • Start by taking a read through the relevant sections of Moving WordPress and Changing the Site URL. If you're still having issues after deploying the procedures listed there, file an edit to update your question with what you've done.
    – bosco
    Jun 1, 2022 at 17:39

1 Answer 1



Found and Fixed the problem. The thing was that yes all the sources in wordpress database pointed to old public ip xxx.xxx.1.163. Which had to be changed.

The things that had to be changed was:

  1. In wp_options
  • Change siteurl

  • Change home url

  1. In wp_posts
  • replace all the old public ip with new public ip

For me as newbie the easiest way to do this was using GUI, for example phpmyAdmin

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.