Record once.
Get Playwright tests that fit your framework.
TestFit records your real browser session as Playwright steps, re-runs it, and writes Playwright TypeScript using your page objects, fixtures and coding guidelines. You get a draft that reuses your code, checked against your repo and reviewed by you before anything is written.
import { test, expect } from '../fixtures'; // โ your fixtures test.describe('Cart', () => { test('user can add a product to cart', async ({ homePage, productPage }) => { await homePage.search('wireless earbuds'); // โ your page object await homePage.openResult(0); await expect(productPage.price).toBeVisible(); await productPage.addToCart(); await expect(productPage.cartBadge).toHaveText('1'); await expect(productPage.addToCartBtn) .toHaveCSS('background-color', 'rgb(255, 159, 0)'); }); });
A real flow, from recording to a reviewed test.
Recorded in the browser, re-run, then turned into Playwright TypeScript that reuses page objects.
โ cart.spec.ts โ 3 passed โ
Most recorders give you code to rewrite.
TestFit drafts it in your framework.
A generic recorder doesn't know your framework, so you end up refactoring every line. TestFit starts from what your team already has.
Generic recorder output
RAW RECORDINGawait page.goto('https://www.flipkart.com/'); await page.locator('input[name="q"]').click(); await page.locator('input[name="q"]').fill('wireless earbuds'); await page.keyboard.press('Enter'); await page.locator('div:nth-child(2) > a').first().click(); await page.locator('button._2KpZ6l').click();
- โRaw locators duplicated across every test
- โIgnores your page objects and fixtures
- โBrittle, generated class names and nth-child selectors
- โNo assertions unless you add them by hand
TestFit output
FRAMEWORK DRAFTawait homePage.goto(); await homePage.search('wireless earbuds'); await homePage.openResult(0); await expect(productPage.price).toBeVisible(); await productPage.addToCart(); await expect(productPage.cartBadge).toHaveText('1');
- โReuses your existing page object methods
- โFollows your fixtures, naming and folder conventions
- โStable locators first: role, label, test-id
- โHTML and CSS assertions added while recording
Illustrative example. Real output depends on your recording, your repo and the AI model, and you review it before it is written.
Everything you need to go from click to a reviewed test.
These are the core features. Install TestFit to explore the rest, since trying it on your own app is the most reliable way to judge it.
Framework profile
Connect your test repo once. TestFit reads its page objects, fixtures and guidelines, and you can pick example files for it to copy. Generated code is asked to follow them, and checked against your guidelines.
Page object matching
Recorded steps map to the methods you already have, like loginPage.login(user), instead of three raw lines.
Real session recording
Clicks, typing, navigation, dropdowns, checkboxes and key presses, captured as you test.
Smart, stable locators
Prefers getByRole, getByLabel and getByTestId, and replaces generated IDs and class names with stable locators.
HTML and CSS assertions
Add visibility, text, value and URL checks while recording, from the panel or a right-click, plus CSS and other checks on any element. TestFit also suggests assertions for what each action changed.
Step editor
Change a step's value or code, or delete it, before you re-run or generate. Fix the flow, not the code.
Secret masking
Passwords, codes and card numbers you type become env variables, not hardcoded values in a spec.
New page objects
Pages your repo doesn't cover yet get new page objects in your style. With no repo, TestFit writes standard Page Object Model code.
Copy or write to your repo
Copy the plain Playwright code at any time, with no AI needed. Or review the generated files and write them straight into your repo.
Bring your own AI, or run it on your machine.
AI is only used to turn a recording into framework code. TestFit sends the request straight from your browser to the provider you choose. There is no TestFit server in between.
Pick a provider
Anthropic, OpenAI or Google Gemini with your own API key, or a local model like Ollama or LM Studio, with no key at all.
See what is sent
Preview the exact request first. Emails and phone numbers are replaced with placeholders, and passwords are never sent.
Checked before you keep it
The code is type-checked against your repo and linted against your guidelines. Problems go back to the AI to fix.
For anyone who needs to keep testing.
SDETs
Skip the boilerplate and spend your time on strategy, flaky tests and coverage gaps.
Manual testers and non-coders
Record what you already test by hand and hand over a working Playwright test an SDET can build on.
Teams without automation yet
Build a test suite from day one, even before a framework is fully in place.
Fast-moving dev cycles
Features keep changing? Re-record in seconds instead of rewriting tests.
Four steps from browser to spec.
Record the flow
Open the side panel, hit record, and test your app the way you normally would.
Add assertions
Check text, visibility, values or CSS, such as toHaveCSS, from the panel or a right-click.
Re-run it
Re-run the steps in a new tab. A failure shows its screenshot, console errors, trace and a ready bug report.
Generate or copy
Connect your repo and generate framework code, or copy the plain Playwright code. Then run npx playwright test.
The details that make tests more reliable.
All of these ship today. Install TestFit to try them on your own app.
Guideline rules
Enforce your rules, like no hard waits and no XPath, and get flagged when generated code breaks one.
Smart waits on re-run
Re-runs wait for the element a step needs and for loading indicators, never a fixed waitForTimeout.
Failures you can act on
See where a re-run failed, with a screenshot, console errors, a Playwright trace and a bug report ready to copy.
Shared across the team
Guidelines live in your repo, and projects export to a file teammates can import, so tests stay consistent.
Scheduled runs
Run chosen sessions once, daily or on set weekdays, and get a notification with the results.
Accessibility checks
Check a page against WCAG rules with axe-core while recording, and keep the check as a test step.
Phones and tablets
Record as a device, with its screen size and touch, and re-run the same way.
Projects
Keep apps or teams apart, each with its own sessions, schedules, secrets and repo.
Spend less time rewriting recorded tests.
Install TestFit free from the Chrome Web Store, record your first flow, and see your own framework come back as code.
Questions, answered.
Is TestFit free?
Yes. TestFit is free to install from the Chrome Web Store, with no sign-up and no credit card. If you generate code with a hosted AI provider, that provider bills your own API key at its usual rates. A local model costs nothing.
Do I need an AI API key?
Only to generate framework code. Recording, assertions, re-runs, schedules and copying the plain Playwright code need no key. To generate code, add a key for Anthropic, OpenAI or Google Gemini, or point TestFit at a local model such as Ollama or LM Studio, which needs no key.
How is this different from Playwright's codegen?
Codegen records raw locators on the page. TestFit maps your steps to your existing page objects, fixtures and coding guidelines, so the output starts from how your team already writes tests.
Is the generated code ready to commit?
Often close, not always. It's a draft. TestFit type-checks it against your repo, lints it against your guidelines and checks its locators on the live page. Problems go back to the AI to fix. Then you review each file before anything is written. Expect to adjust names, test data or an assertion now and then. Long flows, and repos with few page objects, need more review.
We don't have a framework yet. Can I still use it?
Yes. Without a repo, TestFit generates standard Playwright Page Object Model code: page objects in pages/ and specs in tests/, with stable locators and your assertions. It's a good start for a framework.
I'm not a coder. Will this work for me?
Yes. Recording a flow and adding assertions needs no code. You can hand the generated spec to an SDET or developer to add to the repo.
Is my data safe?
Recordings, results and your settings stay in your browser. TestFit has no server and no analytics. Only when you generate code or write a bug report with AI does it send a request, straight from your browser to the provider you chose. You can preview that request first, emails and phone numbers are replaced with placeholders, and passwords are never sent. See the privacy policy.
Why does TestFit need the debugger permission?
TestFit records and re-runs tests with Playwright, which controls a tab through Chrome's DevTools Protocol. It attaches only to the tab you record or re-run, and Chrome shows its "started debugging this browser" banner while it does.
Which frameworks are supported?
TestFit generates Playwright tests in TypeScript.
Latest update.
Code examples, data files and standard page objects
- Code examples. Pick one file each to show how your team writes fixtures, page objects and test data. Your reference tests are the spec example. Generated code follows them, including your data helpers and import paths.
- Data files can be chosen. "Files to refer to" now finds any source file in your repo, including test data in folders like
factories/. - Standard Page Object Model without a repo. With no repo connected, generated code uses standard page objects instead of a single test file.
- Smaller things. Clearer warnings when a code example is missing or too large to send, generated data that keeps the values your assertions expect, keyboard-scrollable code, and a link to this site from the extension.
Need help, found a bug, or want a feature?
Email is the quickest way to reach me. I read every message. For a bug, say what you did, what you expected, and your Chrome version. In the extension, the failed step's Copy bug report button gives you most of that.