You can now ask an AI for "a Django service that does X," and it'll produce views, models, serializers, tests, and maybe a README if you phrase the request nicely. Then real life happens. Three days later you're staring at a repo thinking, "Why does this endpoint exist and why does it take a mode parameter?"
Git is still the source of truth. The AI is just a very fast intern with amnesia who will confidently give you the same wrong answer twice if you let it. Git is the part that remembers.
AI can rewrite files. Git explains why.
Here's the mental model that actually holds up when AI is in the mix:
- Commits are checkpoints. This worked. This shipped. If production catches fire, this is the last known good state you can roll back to without guessing.
- Branches are experiments. Try the weird refactor, the "what if we used Redis here," or the giant rename without spraying it all over
main. - Pull requests are conversations. They carry tradeoffs, "we decided not to do X because…", and the single comment six months from now you'll be grateful for: "Wait, why are we parsing Excel again?"
AI makes it easier to create code, which also means it's now trivially easy to ship confidently wrong code at high speed. Git is how you keep that blast radius contained.
The "AI" that was really spreadsheet work
I worked at a SaaS company that marketed itself as using AI to automate financial tasks. Sounded fancy. A few weeks in, I kept asking support, "Okay, but how does the system actually work?" and kept getting versions of "Just come into the office and watch us do it." Not documentation. Vibes.
When I finally got access to the code, the "AI" turned out to be Excel column mapping and a forest of if-statements that looked at cell colors. Green meant one thing, yellow another. Conditional formatting with a marketing budget.
That job made me picky about process. If your product leans on any amount of "magic," you need a way to prove what actually happened. Git gives you a boring, verifiable trail. Not "the model did something," but a commit you can point at and say, "Here. This is where we changed the rule."
Where to put your Git repo
You can get version control almost anywhere now, but the tradeoffs shift a bit once you add AI to the stack.
GitHub
If you're solo or running a small SaaS, you're probably already on GitHub. Everyone else is.
- Why you care: hiring and sharing are easier because the default answer to "where's the code?" is a link people already know how to use.
- Pricing/lock‑in: you start free, then CI kicks in, Actions minutes get eaten by test runs and build jobs, and suddenly you're at $20/month, then $200, without changing much else.
- AI tie‑in: Copilot is fine, but the real day-to-day win is PR help: summaries, basic review comments, "this file changed a lot" callouts. Your PR turns from 900 lines of mystery into something a human can actually skim.
GitLab
GitLab is the "CI/CD is part of the product, not an add‑on" choice.
- Why you care: pipelines are built in. You can wire up builds, tests, and deployments without learning a second toolchain.
- Pricing/lock‑in: you can self-host and keep everything under your control, but then you're also the one on the hook for upgrades and fixing it when the instance is sad.
- AI tie‑in: it can suggest changes, but the real strength is enforcement: tests must pass, approvals must happen, checks must clear before anything merges. AI can propose whatever it wants; GitLab decides what actually lands.
Bitbucket
Bitbucket shows up in shops that already run on Atlassian tools. It works. People rarely pick it for fun.
- Why you care: the Jira integration is tight, and that matters in companies where the ticket is the unit of reality.
- Pricing/lock‑in: it's often bundled. You're paying for Atlassian anyway, and Bitbucket is just part of that gravity well.
- AI tie‑in: you start with basic stuff and bolt on more with plugins. You won't get the same out-of-the-box AI helpers you see on GitHub without extra wiring.
Self-hosted (Gitea, GitLab, bare Git)
This is for regulated teams, air‑gapped environments, or places where "pushing code to the cloud" triggers a lawyer instead of a deploy.
- Why you care: you decide where the code lives and who can see it. Non‑negotiable in some industries.
- Tradeoffs: you own updates, backups, and uptime. When the Git box falls over, there's no support ticket to file. You're the support.
- AI tie‑in: if you can't send code to external APIs, you run your own models locally and wire up your own bots for review and linting. More work, more control.
Quick Git hosting snapshot
| Topic | GitHub focus | GitLab focus | Bitbucket focus | Self-hosted angle |
|---|---|---|---|---|
| Best for | OSS, small SaaS | Product teams, enterprises | Atlassian‑centric orgs | Regulated, air‑gapped teams |
| Killer bit | Actions + integrations | CI/CD + security features | Jira integration | Compliance, data sovereignty |
| AI angle | Copilot + PR helpers | Checks and gates before merge | Plugins + basic helpers | You roll your own AI and policies |
What actually matters
AI writes code. Git records why you decided to keep it.
If you can't answer "Why did we change this?" from the commit history, you're going to burn a lot of time rediscovering your own decisions six months from now. Whether you're connecting Replit to GitHub or standing up a self-hosted instance behind a VPN, the rule is the same: your code needs version control that lasts longer than your current context window.
-Sethers