Skip to content

Installation Guide

This guide explains how to install WNCMS from scratch on your local machine or production server.

1. Prerequisites

Before proceeding, ensure your environment meets all system requirements:

  • PHP ≥ 8.2
  • MySQL ≥ 8.0
  • Composer ≥ 2.6
  • Node.js ≥ 20
  • Writable directories: storage, bootstrap/cache, public/media

2. Create a New Laravel Project

You can install WNCMS into a fresh Laravel project.

bash
composer create-project laravel/laravel wncms-site
cd wncms-site

3. Install WNCMS Core Package

Run the following Composer command to install the core system:

bash
composer require secretwebmaster/wncms-core

This will install all essential backend components, routes, controllers, and default views for WNCMS.

4. Publish Assets (Optional)

If you want to modify configuration or language files, publish them using:

bash
php artisan vendor:publish --provider="Wncms\WncmsServiceProvider"

You can selectively publish groups such as:

bash
php artisan vendor:publish --tag=wncms-config
php artisan vendor:publish --tag=wncms-lang

5. Set Up the Database

Edit your .env file to configure database credentials:

env
DB_CONNECTION=mysql
DB_HOST=127.0.0.1
DB_PORT=3306
DB_DATABASE=wncms
DB_USERNAME=root
DB_PASSWORD=your_password

Then run the migrations:

bash
php artisan migrate

6. Install Frontend Dependencies (Optional)

If you plan to modify frontend assets or themes:

bash
npm install
npm run build

You can also run:

bash
npm run dev

for live asset rebuilding during local development.

7. Launch the Installation Wizard

Once the database is ready, visit the WNCMS installation route in your browser:

http://your-domain.com/install

The installer will guide you through:

  1. Creating an administrator account
  2. Configuring website name, domain, and default language
  3. Completing system setup

8. Access the Backend

After installation, you can log in to the backend panel:

http://your-domain.com/backend

Use the credentials created during installation.

9. Activate the Default Theme

After logging in:

  1. Navigate to Appearance → Themes
  2. Click Activate next to the desired theme
  3. Visit your frontend site to confirm it’s applied

10. Optional: Install Additional Packages

WNCMS supports modular Composer packages. For example:

bash
composer require secretwebmaster/wncms-faqs
composer require secretwebmaster/wncms-ecommerce

Then activate them in the backend under Packages → Installed Packages.

11. Troubleshooting

If something doesn’t work as expected:

  • Clear cache:

    bash
    php artisan optimize:clear
  • Fix file permissions:

    bash
    chmod -R 775 storage bootstrap/cache public/media
  • Check logs:

    storage/logs/laravel.log

12. Next Steps

You’re now ready to:

Welcome to WNCMS — your Laravel-powered content management platform.

Built with ❤️ for WNCMS