cPanel / Shared Hosting Installation
This guide walks you through installing Genius SMS on a shared hosting account that uses cPanel. Most popular hosting providers (Namecheap, Hostinger, SiteGround, GreenGeeks, etc.) use cPanel.
Before you start — Shared hosting must support PHP 8.3 and allow SSH terminal access (or at minimum allow running Composer). If your host only offers PHP 7.x, you cannot run this application.
What You Need
- A hosting account with cPanel access
- SSH / Terminal access (check your cPanel for "Terminal" under Advanced)
- PHP 8.3 enabled for your account
- A domain or subdomain pointed to your hosting
Step 1 — Create a MySQL Database
- Log into cPanel.
- Go to MySQL Databases.
- Under Create New Database, enter a name (e.g.
youruser_geniussms) and click Create Database. - Under MySQL Users, create a new user with a strong password.
- Under Add User to Database, add the new user to the new database and grant All Privileges.
Write down:
- Database name
- Database username
- Database password
- Host (usually
localhost)
Step 2 — Set PHP Version to 8.3
- In cPanel, go to MultiPHP Manager (or PHP Selector / Select PHP Version).
- Find your domain in the list.
- Set the PHP version to 8.3.
- Save.
Also go to MultiPHP INI Editor and set:
memory_limit = 256M
upload_max_filesize = 50M
post_max_size = 50M
max_execution_time = 300Step 3 — Upload the Application Files
Option A — Upload via File Manager (no SSH needed for upload)
- Download the Genius SMS release ZIP from GitHub.
- In cPanel, open File Manager.
- Navigate to your home directory (
/home/yourusername/). - Create a new folder called
genius-sms(outsidepublic_html— this is important for security). - Upload the ZIP file into
genius-smsand extract it.
Your structure should look like:
/home/yourusername/
genius-sms/ ← application files live here
app/
bootstrap/
config/
database/
public/ ← this folder goes into public_html
resources/
storage/
.env
artisan
composer.json
...
public_html/ ← web root (currently empty or existing site)Option B — Clone via SSH
If your host allows Git:
cd ~
git clone https://github.com/xgenious/genius-sms.git genius-smsStep 4 — Point Your Domain to the Public Folder
The Laravel public/ directory must be the web root for your domain. You have two options:
Option A — Use a Subdomain Pointed to the Public Folder
- In cPanel, go to Subdomains (or Addon Domains).
- Create a subdomain like
school.yourdomain.com. - Set the Document Root to
/home/yourusername/genius-sms/public. - Save.
Option B — Use Your Main Domain
- In cPanel, go to File Manager and open
public_html. - Move or copy everything from
genius-sms/public/intopublic_html/. - Edit
public_html/index.php— change the two paths at the top to point to your app folder:
require __DIR__.'/../genius-sms/vendor/autoload.php';
$app = require_once __DIR__.'/../genius-sms/bootstrap/app.php';- Move the
.htaccessfromgenius-sms/public/intopublic_html/as well.
Option A (subdomain) is simpler and recommended.
Step 5 — Configure the Environment File
In File Manager, navigate to /home/yourusername/genius-sms/.
- Find
.env.example, copy it, and rename the copy to.env. - Right-click
.envand click Edit.
Update these values:
APP_NAME="Genius SMS"
APP_ENV=production
APP_DEBUG=false
APP_URL=https://school.yourdomain.com
DB_CONNECTION=mysql
DB_HOST=localhost
DB_PORT=3306
DB_DATABASE=youruser_geniussms
DB_USERNAME=youruser_dbuser
DB_PASSWORD=your_db_password
REDIS_HOST=127.0.0.1
REDIS_PORT=6379
CACHE_DRIVER=file
SESSION_DRIVER=file
QUEUE_CONNECTION=database
MAIL_MAILER=smtp
MAIL_HOST=mail.yourdomain.com
MAIL_PORT=587
MAIL_USERNAME=noreply@yourdomain.com
MAIL_PASSWORD=your_email_password
MAIL_FROM_ADDRESS=noreply@yourdomain.com
SUPER_ADMIN_EMAIL=admin@yourdomain.com
SUPER_ADMIN_PASSWORD=your_admin_passwordNote: On shared hosting, Redis may not be available. Use
CACHE_DRIVER=file,SESSION_DRIVER=file, andQUEUE_CONNECTION=databaseas shown above.
Save the file.
Step 6 — Install PHP Dependencies via SSH
Open Terminal in cPanel (under Advanced → Terminal) or connect via SSH:
ssh yourusername@yourdomain.comNavigate to the app folder:
cd ~/genius-smsInstall Composer dependencies:
composer install --no-dev --optimize-autoloaderIf Composer is not installed on the server, install it first:
curl -sS https://getcomposer.org/installer | php
php composer.phar install --no-dev --optimize-autoloaderStep 7 — Generate Application Key
php artisan key:generateStep 8 — Run Migrations and Seeders
php artisan migrate --force
php artisan db:seed --forceThis creates all the database tables and sets up the initial super admin account.
Step 9 — Build Frontend Assets
If Node.js is available on your server:
npm install
npm run buildIf Node.js is not available on the server (common on shared hosting), build locally on your computer and upload the compiled files:
On your local machine:
npm install
npm run buildThen upload the entire public/build/ folder to genius-sms/public/build/ on the server using File Manager or FTP.
Step 10 — Set File Permissions
In the SSH terminal:
chmod -R 775 ~/genius-sms/storage
chmod -R 775 ~/genius-sms/bootstrap/cacheOr in File Manager: right-click the storage folder → Change Permissions → set to 755 recursively.
Step 11 — Create the Storage Symlink
cd ~/genius-sms
php artisan storage:linkThis links public/storage to storage/app/public so uploaded files (logos, profile photos) are accessible.
Step 12 — Optimise for Production
php artisan config:cache
php artisan route:cache
php artisan view:cacheStep 13 — Set Up Cron Job
See the Cron Job Setup guide to configure the Laravel scheduler in cPanel.
First Login
Open your browser and go to your domain (e.g. https://school.yourdomain.com).
Log in with:
- Email: value of
SUPER_ADMIN_EMAILin your.env - Password: value of
SUPER_ADMIN_PASSWORD
Updating the Application
When a new version is released:
cd ~/genius-sms
git pull origin main
composer install --no-dev --optimize-autoloader
# Rebuild frontend (or upload the new public/build/ folder)
npm install && npm run build
php artisan migrate --force
php artisan config:cache
php artisan route:cache
php artisan view:cacheTroubleshooting
500 Internal Server Error
Check the Laravel log:
tail -f ~/genius-sms/storage/logs/laravel.logAlso check cPanel → Error Logs.
"Class not found" or composer errors
composer dump-autoload --optimizeUploaded images not showing
php artisan storage:linkMake sure the public/storage symlink exists.
.htaccess not working
In cPanel → File Manager, make sure the .htaccess file exists in your web root (public_html or the domain's document root). Enable Show Hidden Files in File Manager to see it.
Sessions or cache not working
On shared hosting, set CACHE_DRIVER=file and SESSION_DRIVER=file in .env — Redis is often not available.