Upgrading Contensio
How to update Contensio to the latest version — what to run, what to back up, and what to do if something goes wrong.
Contensio is a Laravel package, so upgrading means telling Composer (the tool that manages it) to download the new version and then running any new database changes. The whole process takes about two minutes.
Before you start: always make a database backup first. Upgrades are designed to be safe, but a backup means you can always restore if something unexpected happens.
How to know an update is available
When a new version of Contensio is released, your admin panel tells you automatically:
- Dashboard banner — a blue "Contensio X.X is available" notice appears at the top of the dashboard with the exact commands to run.
- Footer indicator — a small "X.X available" badge appears next to the version number in the bottom-right corner of every admin page.
Both indicators clear automatically once you've upgraded.
If you prefer to check manually, the latest version is always listed on the GitHub releases page.
Upgrading — step by step
Step 1 — Back up your database
Before touching anything, export your database. If something goes wrong, this is your safety net.
Most hosting control panels have a one-click export under Databases → phpMyAdmin or similar. From the command line:
mysqldump -u your_user -p your_database > backup-$(date +%Y%m%d).sql
Step 2 — Connect to your server
You need command-line access to the server where Contensio is installed. This is usually via SSH. If you're on shared hosting, check your control panel for an SSH or terminal option.
If you don't have command-line access, contact your hosting provider — they may be able to run the commands for you.
Step 3 — Run the two upgrade commands
Navigate to your project directory and run:
composer update contensio/contensio
php artisan migrate
That's it. Here's what each command does:
| Command | What it does |
|---|---|
composer update contensio/contensio |
Downloads the new version and updates the files |
php artisan migrate |
Applies any database changes included in the new version |
Step 4 — Clear the cache
After upgrading, clear the application cache to make sure your site picks up the new version:
php artisan optimize:clear
Step 5 — Check your site
Reload the admin panel and confirm the new version number appears in the footer. Browse through the main sections to make sure everything looks normal.
Upgrading on shared hosting (no SSH)
If your hosting doesn't offer SSH access:
- Ask your hosting provider — many hosts will run Composer commands for you on request, especially if you're on a managed plan.
- Use a Composer-compatible control panel — some panels (Plesk, RunCloud, Forge, Ploi) have a built-in interface for running Artisan and Composer commands.
- Set up a deploy pipeline — if you push your code from Git, you can add
composer update contensio/contensio && php artisan migrateto your deploy script so upgrades happen automatically on push.
What gets updated
| What | How |
|---|---|
| Core PHP files | Replaced by Composer — your code in app/, config/, resources/ is untouched |
| Database | php artisan migrate adds new tables or columns — existing data is never deleted |
| Your theme | Not affected unless you're using the built-in default theme; custom themes are yours and are never overwritten |
| Your plugins | Not affected — they're separate packages |
| Your content | Never affected by an upgrade |
Contensio never modifies files outside the vendor/contensio/ directory during an upgrade.
Disabling the update checker
The version check pings GitHub at most once every 12 hours. If your server is offline, air-gapped, or you'd rather not make that request, you can disable it by adding this to your .env:
CONTENSIO_VERSION_CHECK=false
Troubleshooting
"composer: command not found"
Composer is not installed globally. Either install it (see getcomposer.org) or run it with php composer.phar update contensio/contensio if you have composer.phar in your project root.
"Nothing to install, update or remove"
You're already on the latest version. You can verify by checking the version in your admin footer against the latest release.
Migration fails with an error
First, check the exact error message — it usually points to the specific table or column. Common causes:
- A table already exists from an older manual migration — safe to drop it and re-run.
- Insufficient database privileges — the DB user needs
ALTER TABLEpermission.
The site shows a 500 error after upgrading
Run php artisan optimize:clear to clear cached config, routes, and views. If the error persists, check storage/logs/laravel.log for the exact message.
I need to roll back
- Restore your database backup from Step 1.
- Re-install the previous version:
(Replacecomposer require contensio/contensio:1.0.01.0.0with the version you were on.)
Staying informed
- GitHub releases — every release has a changelog explaining what changed, what's new, and whether there are any manual steps required.
- Watch the repo — click "Watch → Releases only" on GitHub to get an email whenever a new version drops.