How to Install WordPress at Home and Host It Free
WordPress powers a huge share of the web — and it runs fine on a laptop. The usual catch is that "running WordPress" normally means renting a VPS or fighting with cPanel hosting. With HWS you skip the middleman: the daemon ships a PHP runtime, your site folder is the web root, and the database lives on your own machine. The result is a real WordPress install at a real public URL — hweb.site/your-slug/ — for free.
This guide walks through the whole thing: getting WordPress files into your project, standing up a local MySQL/MariaDB, wiring wp-config.php for the subdirectory install, and running the installer.
What you need
- HWS installed and paired — download, sign in, done. PHP execution is free on every plan, so WordPress works out of the box.
- A project folder — any empty folder works; WordPress files go straight into it.
- A local MySQL or MariaDB server — WordPress needs a database. XAMPP, MAMP, a standalone MariaDB, or your distro's package all work. Nothing database-related is hosted by HWS — your DB stays on your machine and only your PC talks to it.
- ~15 minutes and a browser.
Step 1 — Point HWS at a project folder
Create the project
In the HWS dashboard, create a project and pick an empty folder as its root — call it mysite or whatever you like. Pick a slug like blog; your site will live at hweb.site/blog/.
Make sure PHP execution is enabled for the project (it's on by default). The dashboard shows the detected PHP version — the bundled runtime is PHP 8.4, plenty for current WordPress.
Step 2 — Get the WordPress files in
Download and extract WordPress into the folder
Grab wordpress.org/latest.zip, unzip it, and copy everything inside the wordpress/ folder into your project root. The folder should end up with index.php, wp-admin/, wp-includes/, and friends at the top level — not nested inside a wordpress/ subfolder.
Step 3 — Stand up the database
Create a database and a dedicated user
Start your MySQL/MariaDB server and create a database plus a user that only has rights to it:
CREATE DATABASE wp_blog CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci;
CREATE USER 'wp_blog'@'127.0.0.1' IDENTIFIED BY 'a-strong-password';
GRANT ALL PRIVILEGES ON wp_blog.* TO 'wp_blog'@'127.0.0.1';
WordPress connects over 127.0.0.1:3306 — plain localhost, nothing exposed to the internet. Keep the credentials out of any public file; they live only in wp-config.php, which HWS blocks from being served.
Step 4 — Configure wp-config.php for the subdirectory install
Set the database and the public URLs
Copy wp-config-sample.php to wp-config.php and fill in your DB credentials. Then add the block that makes WordPress understand it lives at /your-slug/ behind the tunnel:
define('WP_HOME', 'https://hweb.site/your-slug');
define('WP_SITEURL', 'https://hweb.site/your-slug');
Two more lines matter on HWS:
- HTTPS behind the proxy — traffic arrives at your PC as plain HTTP, so force SSL when the proxy header says so:
if (isset($_SERVER['HTTP_X_FORWARDED_PROTO']) && $_SERVER['HTTP_X_FORWARDED_PROTO'] === 'https') { $_SERVER['HTTPS'] = 'on'; } - REQUEST_URI prefix — the tunnel strips your slug before PHP sees the request, so restore it or permalinks and canonical redirects break:
if (isset($_SERVER['REQUEST_URI']) && strpos($_SERVER['REQUEST_URI'], '/your-slug') !== 0) { $_SERVER['REQUEST_URI'] = '/your-slug' . $_SERVER['REQUEST_URI']; }
Also add define('FS_METHOD', 'direct'); so theme and plugin installs write files without asking for FTP credentials.
Step 5 — Run the installer
Open the site and finish setup
Visit https://hweb.site/your-slug/ — WordPress detects the fresh install and walks you through language, site title, and admin account. After that you're in: /your-slug/wp-admin/ is your dashboard.
In Settings → Permalinks, pick Post name — the built-in front controller handles pretty URLs, no .htaccess rewrite rules needed.
Keeping it running
- Your PC is the server. WordPress is live while hwsd runs and your database is up. Sleep the laptop and visitors see the offline page (ProMax's serve-when-offline can keep a cached copy up).
- Autostart both. HWS registers itself at login; do the same for your database (a service on Windows, launchd on macOS, a systemd user unit on Linux).
- Cache mode matters. Live Editing is right while you build; switch to Balanced or High-cache once the site is finished so pages load fast and keep working between visits.
- Back up the folder + database. Both live on your machine — an occasional copy of the project folder and a mysqldump is your whole backup story.