RunCloud provides a straightforward method for temporarily changing your web application’s “public path”. This technique lets you point your domain to a static HTML page instead of your main website files.

It’s fast, easy, and reliable for most sites hosted on RunCloud, whether they’re WordPress, Laravel, a custom PHP app, or even a basic static site.

Why You’d Want To Change Your Website’s Public Path

  • Maintenance Mode: If you’re updating WordPress core, themes, or plugins, running composer update on a Laravel site, performing database schema changes, or doing other backend work that could temporarily break the site, you can change the website’s homepage to display a professional “We’ll be back soon!” message instead of showing errors or a half-broken site.
  • “Coming Soon” Page: If your website’s domain is live and configured in RunCloud, but the actual website development isn’t finished, you can present a polished “Coming Soon” page immediately. This establishes your web presence, looks far better than a default server page, and can even include an email signup form to capture leads before launch.
  • Temporarily Disabling a Site: Temporarily blocking internet traffic on a website can be useful if you find a critical security vulnerability that needs patching, a major bug is causing issues, a client hasn’t paid their hosting bill, or you need to halt activity before a large migration. This method instantly takes the entire application offline, preventing further access or potential damage.

Benefits of This Approach

Changing the public path is often the simplest and quickest way to display a temporary static page. Here’s why it’s so beneficial:

  • Simplicity: This doesn’t require editing the .htaccess file, installing plugins, or deploying highly technical maintenance code. You only need to create one simple HTML file and change one setting in your RunCloud panel.
  • Speed: Implementation takes only a minute or two, and reverting is just as fast.
  • Universality: Because this change happens at the web server configuration level (managed by RunCloud), it works regardless of your website’s technology stack (WordPress, Joomla, Drupal, Laravel, Symfony, Node.js, static HTML, etc.).
  • Resource-Light: Serving a single, basic HTML file puts almost zero load on your server compared to installing a new plugin or framework just to display a maintenance message.
  • Control: You can create your own index.html file, which gives you complete control over the message, branding, and styling of your temporary page.

Steps to Temporarily Disable a Website on RunCloud

Ready to try it? Here’s how easy it is:

Step 1: Create Your Temporary Content Folder and File

Use the RunCloud File Manager and navigate to your web application’s root directory. Create a new folder inside this directory. For this example, let’s name it disabled, but you could call it maintenance, coming soon, or anything descriptive. However, avoiding spaces in file names is recommended to avoid unnecessary headaches during the configuration step.

Inside this new ‘disabled’ folder, create a file named index.html (or index.php).

Step 2: Customize Your Temporary index.html Page

Click on the index.html file to open up a text editor in a new window. Here you can edit the index.html file you just created. In this file, add the basic HTML (or PHP) structure and the message you want to display.

Example index.html for a disabled site:

<!DOCTYPE html>
<html>
<head>
    <title>Site Disabled</title>
    <style>
        body { font-family: sans-serif; text-align: center; padding-top: 50px; }
    </style>
</head>
<body>
    <h1>This Website is Temporarily Disabled</h1>
  <p>We apologize for the inconvenience. Please check back later.</p>
</body>
</html>

Depending on your use case (Maintenance, Coming Soon, etc.), feel free to add more styling, logos, or different messages. After you have finished editing the file, make sure to click the Save button in the top right corner of your screen.

Step 3: Change the Public Path in RunCloud

  • Go back to your RunCloud dashboard and navigate to Your Server -> Web Applications -> Your Application Name.
  • Go to the Settings tab for that specific web application and find the Public Path setting. Depending on your setup, it likely shows an empty text field or perhaps /public or /web. Make a note of this original path!
  • Change the value to / followed by the name of the folder named in Step 1. In our example, you would enter: /disabled

Step 4: Save Changes and Verify

  • Scroll down and click the “Update Stack” button in RunCloud. Wait a few moments for RunCloud to apply the configuration change to your web server.
  • Open your website in a web browser. You might need to do a hard refresh (Ctrl+Shift+R or Cmd+Shift+R) or clear your cache.
  • You should now see the content of your disabled/index.html file instead of your live website.

Step 5. Reverting to Your Live Site

Returning your website to its normal state is just as easy:

  1. Go back to your Web Application’s Settings page in RunCloud and locate the Public Path setting.
  2. Change it back to the original path you noted before (e.g., //public, etc.).
  3. Click “Update Stack”.

Important Considerations

  • Git/Atomic Deployments: If you use RunCloud’s Git Deployment that automatically manages your webroot via symbolic links (symlinks), changing the Public Path in RunCloud might be overwritten on your next deployment. In such cases, you might need to use framework-specific maintenance modes (like php artisan down in Laravel) or handle maintenance pages within your deployment script logic.
  • SEO Impact: Search engines might crawl your site while it shows the temporary page. This is usually fine for short maintenance periods. For longer durations, it can negatively impact your SEO rankings. Ideally, the server should send a 503 Service Unavailable HTTP status code for proper maintenance. While this simple index.html method typically serves a 200 OK, it’s often sufficient for short-term needs. Refer to our documentation on creating a custom NGINX configuration file and creating redirects with Nginx (Temporary and Permanent) to learn more.
  • Caching: Browser or even server-side caching might delay seeing the changes. If the site doesn’t update immediately, always try a hard refresh or clear relevant caches.