Set up the Momentic CLI, skills, and MCP server for a web project.
1. Prerequisites
- Node.js 20.19.0+, 22.12.0+, or 24.0.0+
- A
package.jsonin your project (runnpm init -yif you don’t have one) - A Momentic account, sign up to generate an API key
2. Install
3. Authenticate
Create an API key in the dashboard, then export it:Persist the key by appending the
export line to ~/.zshrc (macOS) or
~/.bashrc (Linux). In CI, set MOMENTIC_API_KEY as a secret environment
variable.4. Initialize
momentic.config.yaml, your project configurationexample-test.test.yaml, a starter test scaffold
5. Install browsers
Momentic runs your tests against a headless browser. Install Chromium:6. Write your first test
Open the local editor:- Name:
example-test - Base URL:
https://practicetestautomation.com/practice-test-login/
example-test.test.yaml.
7. Run from the CLI
8. Verify
- Check
example-test.test.yamlexists in your project root - Open the dashboard and check Runs for the result
9. Next steps
Core concepts
Finding elements, writing assertions, modules, variables
CI/CD
Run Momentic on every pull request
Best practices
Write tests that hold up over time