Foam vs Khoj

A side-by-side comparison of two self-hosted notes & knowledge base options — licensing, setup difficulty, resource needs, and what each one replaces.

Not the right match-up?
FeatureFoamKhoj
CategoryNotes & Knowledge BaseNotes & Knowledge Base
LicenseMITAGPL-3.0
LanguageTypeScriptPython
Setup difficultyEasyMedium
Min. RAM256 MB2,048 MB
Deploymentsourcedocker, bare-metal, source
GitHub stars★ 17,328★ 36,386
First released20202021
ReplacesRoam Research, ObsidianNotion AI, Evernote

Why pick each one

Choose Foam if…

  • Released under the MIT license
  • Easy to set up — beginner-friendly
  • Mature project with 17.3k GitHub stars
  • Written in TypeScript
Foam details

Choose Khoj if…

  • Turns notes into an AI knowledge base
  • Supports local LLMs
Khoj details

Frequently asked questions

Is Foam or Khoj better?

Neither is universally better. Khoj has the larger community, while Foam is simpler to set up (easy difficulty). Choose based on the comparison table above and your own setup.

Are Foam and Khoj free and open-source?

Yes. Foam is licensed under MIT and Khoj under AGPL-3.0. Both can be self-hosted at no software cost.

Can I run Foam and Khoj with Docker?

Foam: check the project docs for container support. Khoj: yes.

Related comparisons