Difference Between home_url() and site_url() in WordPress

,

difference between home_url() and site_url()

home_url() and site_url() in WordPress is very simple thing, but could be little bit confusing. Look at the image, then I described below –

From Setting -> General
1) WordPress Address (URL) = site_url()
2) Site Address (URL) = home_url( )

You could force rewrite that from wp-config.php too. Remembering is easy, its just opposite to what is says, so in Setting “Site Address (URL)” is home_url not the site_url as it looks from the words. Savvy?

Detail Discussion:
1) StackExchange

Codex:
1) site_url
2) home_url

Leave a Reply

Your email address will not be published. Required fields are marked *