The toolkit: 36 free CBT tools, vanilla JS, zero signup, zero backend, zero dependencies. Live at alexcoledev.github.io/cbt-toolkit.
I built it because therapy apps cost $50-200/year and upload your thoughts to their servers. Here is how the architecture actually compares.
The Contenders
| Tool | Type | Cost | Where your data lives |
|---|---|---|---|
| cbt-toolkit (mine) | 36 vanilla JS tools | $0 | Your browser (localStorage) |
| Woebot | AI chatbot | $35/mo | Their servers |
| Wysa | AI chatbot | $20/mo | Their servers |
| Moodnotes | Thought record app | $4 + IAP | iCloud (if synced) |
| Sanvello | CBT + meditation | $9/mo | Their servers |
| CBT-i Coach | Insomnia CBT | $0 (VA) | Their servers |
Architecture Difference 1: Where Your Thoughts Live
This is the one that matters most to me.
Paid apps: You type "I feel like everyone is judging me" → it goes to their server → they run ML on it → they send back a response. Your raw thoughts are stored on someone else's infrastructure.
cbt-toolkit: You type "I feel like everyone is judging me" → the JavaScript runs in YOUR browser → localStorage.setItem() → it stays on your device. No network request. No server. No database.
// The entire "database" — 40 lines
const DB = {
save(entry) {
const records = JSON.parse(localStorage.getItem('cbt_records') || '[]');
records.push({ ...entry, id: Date.now(), timestamp: new Date().toISOString() });
localStorage.setItem('cbt_records', JSON.stringify(records));
},
getAll() {
return JSON.parse(localStorage.getItem('cbt_records') || '[]');
}
};
Your most vulnerable thoughts — the ones you write at 2am when you are anxious — never leave your machine. There is no API endpoint. There is no server log. There is no data breach surface.
Architecture Difference 2: Rule-Based vs ML
Paid apps (Woebot, Wysa): Use LLMs/NLP to generate responses. The advantage: personalized, conversational. The cost: non-deterministic (same input → different output), requires server compute, your data trains their models.
cbt-toolkit: Uses keyword-pattern matching against CBT-defined categories. The advantage: deterministic, zero-latency, zero-cost, explainable. The tradeoff: no conversational flexibility.
// The distortion detector — pattern matching, not ML
const DISTORTIONS = [
{ name: 'all-or-nothing', keywords: ['always', 'never', 'completely', 'total failure'] },
{ name: 'catastrophizing', keywords: ['what if', 'end', 'disaster', 'heart attack'] }
];
function detectDistortions(text) {
return DISTORTIONS
.filter(d => d.keywords.some(kw => text.toLowerCase().includes(kw)))
.map(d => ({ distortion: d.name, reframe: REFRAMES[d.name] }));
}
Same input → same output. Every time. For a clinical technique where consistency matters, this is a feature, not a bug.
Architecture Difference 3: Accessibility
Paid apps: Download from app store → create account → verify email → subscribe → now you can use it. 5 steps before you see your first tool.
cbt-toolkit: Open URL → use tool. That is it. No install. No account. No email. Works offline after first load (it is just HTML/JS/CSS). Works on any device with a browser.
The Honest Tradeoff
I am not going to pretend my toolkit is better than Woebot at everything. It is not.
Where paid apps win:
- Personalized conversational responses (my tools give the same reframe every time)
- Professional therapist integration (some apps connect you to real therapists)
- Progress coaching and reminders
- Medically-reviewed content pathways
Where cbt-toolkit wins:
- Cost: $0 vs $240-2400/year
- Privacy: thoughts never leave your device
- Speed: instant, no network round-trip
- Transparency: the detection logic is open-source and auditable
- Accessibility: no signup wall, works on any browser, works offline
- Determinism: same thought → same analysis (reproducible)
When To Use Which
- Use a paid app if you want conversational support, therapist integration, or structured coaching programs
- Use cbt-toolkit if you want free, private, instant self-guided CBT exercises — thought records, distortion detection, safety behavior tracking, habituation logging, core belief drilling
They are not mutually exclusive. I use my own toolkit for quick thought records and a paid app when I want someone to talk to.
The 36 Tools
The toolkit includes:
- Cognitive Distortion Detector (10 distortions, keyword-pattern matching)
- Core Belief Detector (downward arrow technique, 13 terminal beliefs)
- Safety Behavior Detector (9 CBT behavior categories)
- Habituation Pattern Detector (time-series trend analysis)
- Catastrophe Prediction Calibration Detector (disconfirmation rate tracking)
- CBT Thought Record (5-column classic format)
- Panic Diary (with reframe generation)
- OCD/ADHD/PTSD/Shame/Anger specific tools
- ...and 28 more
All vanilla JS. All client-side. All free. All at alexcoledev.github.io/cbt-toolkit.
Why I Built It This Way
I wanted CBT tools that:
- Cost nothing (CBT should not be paywalled)
- Keep my thoughts private (they are the most sensitive data I have)
- Work instantly (no loading screens, no API latency)
- Are auditable (I can read the detection logic and know exactly why it flagged something)
Vanilla JS + localStorage is the simplest architecture that satisfies all four. No framework. No backend. No database. No API. No signup. Just HTML, JS, and your browser.
The toolkit is open-source: github.com/alexcoledev/cbt-toolkit. 36 tools, 12 detectors, zero dependencies. Star it if it helps.
Top comments (0)