Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7009077
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T21:49:00+00:00 2026-05-27T21:49:00+00:00

Ive configured Apache for Name-based Virtual Hosting but I can’t seem to get a

  • 0

Ive configured Apache for Name-based Virtual Hosting but I can’t seem to get a local site to show in my browser. Is my httpd.conf misconfigured? Here’s the sanitized version:

#
# Use Name-based Virual Hosting.
#
NameVirtualHost *.:80

#
#Set up permissions for VirtualHosts in ~/Sites
#
<Directory "/Users/myusername/Sites">
    Options Indexes FollowSymLinks MultiViews
    AllowOverride All
    Order allow,deny
    Allow from all
</Directory>

# For http://localhost in the OSX default location
<VirtualHost _default_:80>
    ServerName localhost
    DocumentRoot /Library/WebServer/Documents
</VirtualHost>

<VirtualHost *:80>
    ServerName thewebsite.local
    CustomLog "/Users/myusername/Sites/logs/thewebsite.local-access_log" combined
    ErrorLog "/Users/myusername/Sites/logs/thewebsite.local-error_log"
    DocumentRoot "/Users/myusername/Sites/thewebsite.local"
</VirtualHost>

And my etc/hosts

##
# Host Database
#
# localhost is used to configure the loopback interface
# when the system is booting.  Do not change this entry.
##
127.0.0.1       thewebsite.local
127.0.0.1       localhost
255.255.255.255 broadcasthost
::1             localhost
fe80::1%lo0     localhost
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-27T21:49:00+00:00Added an answer on May 27, 2026 at 9:49 pm

    Try changing the first line to be NameVirtualHost *:80 instead of NameVirtualHost *.:80.
    Also, add your documentRoot for _default_ in quotes DocumentRoot "/Library/WebServer/Documents" (just to be consistent across the file.)
    Also try adding the Directory permissions inside the Virtual Host.

    I have made the changes in the code below. Try them.

    #
    # Use Name-based Virual Hosting.
    #
    NameVirtualHost *:80
    
    
    # For http://localhost in the OSX default location
    <VirtualHost _default_:80>
        ServerName localhost
        DocumentRoot "/Library/WebServer/Documents"
    </VirtualHost>
    
    <VirtualHost *:80>
        ServerName thewebsite.local
        CustomLog "/Users/myusername/Sites/logs/thewebsite.local-access_log" combined
        ErrorLog "/Users/myusername/Sites/logs/thewebsite.local-error_log"
        DocumentRoot "/Users/myusername/Sites/thewebsite.local"
        <Directory "/Users/myusername/Sites">
            Options Indexes FollowSymLinks MultiViews
            AllowOverride All
            Order allow,deny
            Allow from all
        </Directory>
    </VirtualHost>
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am running Ubuntu8.041. Apache/2.2.8 (Ubuntu) PHP/5.2.4-2ubuntu5.3 with Suhosin-Patch configured Can't get file uploading
I've configured an SMTPAppender into my Java app. <appender name=AdministratorEmail class=org.apache.log4j.net.SMTPAppender> <param name=Threshold value=info
I've got it configured, but I want more from it...maybe Cygwin isn't the right
How can I configure Tomcat (in standalone mode, that is without Apache [*]) so
I've built a vagrant/virtualbox web server as a development sandbox, and configured apache in
I've got a large Django app. It has two Apache virtual hosts pointing to
I've done a fair bit of reading on NuGet, and I can't seem to
I searching for an open source TCP server that can be configured on the
I can't get server side includes to work. I simply want to include one
I've just set up nginx to serve static request on one site, but I

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.