Diagnosing DNS and Host Configuration
The most common cause for this discrepancy is that the subdomain photos does not resolve to the same IP address as the main domain, or the web server is not configured to handle requests for that specific hostname. When you visit jeffbloom.net/photos, you are accessing a path on the main domain’s document root. However, photos.jeffbloom.net is treated as a completely separate entity by browsers and servers.
First, verify that your DNS settings are correct. Log into your domain registrar or DNS provider (such as Cloudflare, GoDaddy, or Namecheap) and ensure there is an A record or CNAME record for photos. If you are using an A record, it must point to the exact public IP address of your hosting server. If you are using a CNAME, it should point to your primary domain name (e.g., jeffbloom.net). If these records are missing or point to an incorrect location, the browser will either fail to connect or receive no content.
If your DNS is correct, check your hosting control panel. Many shared hosting environments require you to explicitly create the subdomain in the interface (cPanel, Plesk, etc.). Creating the subdomain here usually sets up the necessary directory structure and DNS entries automatically. If the subdomain was created manually via DNS but not registered in the hosting panel, the server will not know which files to serve when a request arrives for photos.jeffbloom.net.
Web Server Virtual Host Settings
Once DNS and hosting panels are confirmed, the issue often lies within the web server configuration, such as Apache or Nginx. Your server needs a Virtual Host (Apache) or Server Block (Nginx) specifically defined for photos.jeffbloom.net. If only a default virtual host exists for www.jeffbloom.net or jeffbloom.net, the server may return a blank page or a 404 error because it doesn’t recognize the subdomain as a valid target.
In Apache, you would look for a file in /etc/apache2/sites-available/ or similar. Ensure there is a directive like:
<VirtualHost *:80>
ServerName photos.jeffbloom.net
DocumentRoot /var/www/photos/public
</VirtualHost>
If this block is missing, add it and restart Apache. For Nginx, check your sites-enabled directory for a configuration block that matches server_name photos.jeffbloom.net;. Without this explicit mapping, the server falls back to the default site, which might be empty or misconfigured for the subdomain context.
Application-Level Routing and Framework Issues
If your website runs on a framework like WordPress, Laravel, or Ruby on Rails, the application itself might be rejecting the subdomain. In many CMS platforms, the base URL is hardcoded. For example, if your WordPress Site Address (URL) is set to https://jeffbloom.net, it may ignore requests to photos.jeffbloom.net unless properly configured.
Check your application’s configuration files. In Laravel, ensure that APP_URL in your .env file allows for subdomains or is set correctly. In Rails applications, you might encounter issues where the subdomain is blocked or not recognized by the router, especially if strict domain constraints are applied. Refer to our guide on Subdomain Blocked in Rails 5: A Tech Support Guide if you are using a Ruby-based stack, as framework-specific routing rules can easily cause blank pages if the subdomain isn’t explicitly permitted in the route constraints.
Additionally, check for mixed content issues. If your main site loads over HTTPS but the subdomain tries to load resources over HTTP, modern browsers may block the content, resulting in a blank white screen. Use your browser’s Developer Tools (F12) and look at the Console tab for any CORS or mixed-content errors.
Caching and Propagation Delays
After making changes to DNS or server configurations, caching can persist the old state. Clear your browser cache, or try accessing the subdomain in an incognito window. If you use a CDN like Cloudflare, purge its cache to ensure the latest DNS records are served globally. DNS propagation can take up to 48 hours, though it often happens much faster. If the issue persists after several hours, re-check your DNS records for typos.
For more general troubleshooting on URLs that behave inconsistently, see Troubleshooting: URL Not Working Properly for additional diagnostic steps regarding network connectivity and server responses.
Frequently Asked Questions
Why does the main domain work but the subdomain shows a blank page?
This happens because the subdomain is treated as a separate entity with its own DNS and server configuration. While the main domain points to a working document root, the subdomain may lack a proper virtual host definition or DNS record, causing the server to return empty content.
How long does DNS propagation take for a new subdomain?
DNS propagation typically takes anywhere from a few minutes to 48 hours, depending on the TTL (Time To Live) settings of your previous records. Most modern providers update within an hour, but global caches may still hold older data temporarily.
What should I check first if my subdomain is blank?
Start by verifying your DNS A record or CNAME to ensure photos points to your server’s IP. Next, confirm that the subdomain is created in your hosting control panel so the server knows which directory to serve.
Can a firewall block a subdomain while allowing the main domain?
Yes, if your firewall rules are IP-based, both domains will work since they share the IP. However, if you have application-level firewalls or WAFs that restrict specific hostnames, the subdomain might be blocked while the main domain remains accessible.
How do I clear my browser cache for a subdomain?
You can clear your cache by pressing Ctrl+Shift+Delete (Windows) or Cmd+Shift+Delete (Mac) and selecting cached images and files. Alternatively, use an Incognito or Private browsing window to bypass local caching entirely.