Loopress CLI
The Loopress CLI (lps) is a Node.js command-line tool that connects to the WordPress REST API to sync code snippets and plugins between your local machine and any WordPress instance.
The Loopress WordPress plugin must be installed and active on the site you want to manage.
Command overview
Section titled “Command overview”Commands for managing the tool itself, your projects, and your Loopress account:
| Group | Command | Description |
|---|---|---|
| Auth | lps login |
Log in to the Loopress console |
lps logout |
Log out from the Loopress console | |
| Setup | lps init |
Create a loopress.json config file interactively |
lps status |
Show which project and environment commands will target | |
lps doctor |
Diagnose connectivity, plugin and credential problems | |
lps validate |
Check local tracked files are well formed and push-ready, without contacting WordPress | |
lps dev |
Watch snippets, pages, API routes and plugins, pushing each change to the local environment automatically |
|
lps push |
Push plugins, composer, ACF, API routes, forms, pages, SEO, and snippets to WordPress in one command | |
lps pull |
Pull plugins, composer, ACF, API routes, forms, pages, SEO, and snippets from WordPress in one command | |
lps promote |
Copy every tracked resource from one environment to another (lps pull from the source, then lps push to the target) |
|
| Project | lps project config |
Add or update a WordPress project environment |
lps project list |
List configured WordPress projects | |
lps project switch |
Switch the active project and environment | |
lps project remove |
Remove one or more WordPress projects or environments | |
lps project push |
Push locally configured projects, environments and credentials to your Loopress account | |
lps project pull |
Pull projects and environments from your Loopress account that aren’t configured locally yet | |
lps project rotate |
Rotate the WordPress application password for a project | |
| Telemetry | lps telemetry enable |
Enable error reporting to Sentry |
lps telemetry disable |
Disable error reporting to Sentry |
Features
Section titled “Features”Each of these syncs one kind of WordPress data as files in Git. See its own page for commands, flags, and file format:
- Snippets: PHP/CSS/JS code snippets (Code Snippets or WPCode)
- ACF: Advanced Custom Fields configuration
- SEO: SEO settings, post meta, and redirects (RankMath or Yoast)
- Forms: WPForms forms
- API Routes: custom REST API endpoints
- Plugins: installed WordPress.org plugins manifest
- Composer: PHP dependencies, without SSH
Connecting an AI agent instead of a human? See the MCP server.
Quick start
Section titled “Quick start”# 1. Connect to your WordPress sitelps project config
# 2. Initialize your project configlps init
# 3. Pull your snippetslps snippet pull
# 4. Edit, commit, pushgit add snippets/ && git commit -m "update snippet"lps snippet push→ Full CLI installation and setup guide
Authentication
Section titled “Authentication”All commands authenticate against WordPress using an Application Password. By default, lps project config creates one automatically by authorizing in your browser. Generating one manually under Users → Profile → Application Passwords is available as a fallback.
The CLI supports managing multiple projects (lps project config) and switching between them (lps project switch).