略過並前往主要內容
致電我們
服務專線和服務時間
預約回電

無須線上等候,提交預約我們將儘快回電。

預約回電
說明中心

瀏覽我們線上說明資源

說明

GoDaddy 說明

Preview your website using hosts files

Sometimes you need to preview your website files on your hosting account prior to pointing your domain to your hosting account. You can do this by adding entries to the hosts file on your local computer. Keep in mind that we don't support modifying your system files, you're doing so at your own risk.

Required: You’ll need a third-party text editor, like Notepad++, to make any necessary changes. Don't edit this file directly in a word processing application like Microsoft Word.
  1. Start by finding the location of your host file:
    OS Host File Location
    Windows (10, 8, 7, XP, etc.) c:\windows\system32\drivers\etc\hosts
    Macintosh OS X /private/etc/hosts
    Linux /etc/hosts
  2. Now, add an entry to your host file for your domain and hosting account using the following format:

    [your hosting account's IP address] [your domain name] [your domain name with www]

    For example:

    12.0.0.1     coolexample.com     www.coolexample.com
  3. Save the changes to your host file and navigate to your domain name using your preferred browser. The website files on your hosting account will load, allowing you to preview your website.
Warning: After you're done previewing your website, and pointing your domain name to your hosting account, be sure to remove the entry from your hosts file. If you don't remove the entry and change plans or servers in the future, you won't be able to view your site.

More info

If you don't know the IP address of your hosting account, but you know what kind of hosting you have you can find out your IP address using the links below:

相關社群

icparklinsO's Avatar
Website Page Not Found

2 回覆

Last posted over 3 years ago.

Mikeyb's Avatar
No preview of website after FTP transfer

3 回覆

Last posted over 4 years ago.

CommunityUser's Avatar
New account, getting 404 for preview

6 回覆

Last posted over 1 year ago.

找不到主題嗎?搜尋社群