Skip to content

cmd uninstall

github-actions[bot] edited this page May 18, 2026 · 1 revision

nself uninstall

Remove nSelf-generated files and containers from the current project directory.

Synopsis

nself uninstall [flags]

Description

nself uninstall stops running containers and deletes files that nSelf generated for the current project: docker-compose.yml, the nginx site configs in nginx/sites/, and the .nself/cache/ directory. Your .env* files, hand-managed nginx/conf.d/ fragments, and application source code are never touched.

By default the command keeps Postgres database volumes so your data survives the removal. Add --purge to also delete the volumes. The command is interactive by default: it describes what it will do and prompts for confirmation before proceeding. Use --yes to skip prompts in scripted or CI environments.

Warning: Data Loss Risk. Running nself uninstall --purge permanently deletes the Postgres database volumes for this project. This action cannot be undone. Keep a backup before running --purge, or omit the flag to preserve your data.

Flags

Flag Short Type Default Description
--keep-data bool false Keep database volumes (the default behaviour when no flag is given)
--purge bool false Remove everything including database volumes. Destructive and permanent
--yes -y bool false Skip all confirmation prompts

--keep-data and --purge are mutually exclusive.

Examples

# Interactive uninstall, keeps DB volumes (default)
nself uninstall
# Same as default, explicit flag
nself uninstall --keep-data
# Remove everything including the database (prompts for "purge" confirmation)
nself uninstall --purge
# Non-interactive full purge for CI teardown
nself uninstall --purge --yes
# Reinitialise from scratch after uninstall
nself init --force && nself build && nself start

See Also

Commands | Home

Home


Getting Started


Commands


Features


Configuration


Plugins (87 + 10 monitoring)

Free (25)
Pro (62)
Planned (26)
  • plugin-audit
  • plugin-blog
  • plugin-checkout
  • plugin-commerce
  • plugin-drm
  • plugin-export
  • plugin-flow
  • plugin-import
  • plugin-ldap
  • plugin-mailgun
  • plugin-media
  • plugin-oauth-providers
  • plugin-pages
  • plugin-postmark
  • plugin-rate-limit
  • plugin-reports
  • plugin-saml
  • plugin-scheduler
  • plugin-sendgrid
  • plugin-sso
  • plugin-subscription
  • plugin-thumb
  • plugin-transcoder
  • plugin-twilio
  • plugin-waf
  • plugin-watermark

Guides


Architecture


Reference


Licensing


Security


Brand


Operations


Contributing


Admin


Changelog

Clone this wiki locally