---
title: "How to Fine-Tune an LLM for $0 in 2026: Colab, Kaggle and Unsloth"
slug: "fine-tune-llm-free"
description: "Fine-tune a small open model on a free GPU: Kaggle 30 hours a week, Colab sessions, Unsloth QLoRA and how much VRAM each model size needs, with sources."
published: "2026-10-26"
updated: "2026-10-26"
verifiedAt: "2026-10-26"
canonical: "https://aifree.dev/learn/fine-tune-llm-free"
---

# How to Fine-Tune an LLM for $0 in 2026: Colab, Kaggle and Unsloth

> Fine-tune a small open model on a free GPU: Kaggle 30 hours a week, Colab sessions, Unsloth QLoRA and how much VRAM each model size needs, with sources.

- Time: 1 to 3 hours for a first QLoRA run on a small model
- You need: A Google account (Colab) or a Kaggle account with a verified phone number; A dataset of a few hundred to a few thousand question-and-answer pairs; A Hugging Face account to download base models and save your adapter
- Last checked: 2026-10-26

You can fine-tune an open model of up to about 14 billion parameters without paying anything. The free path is QLoRA: load the base model in 4-bit, train a small adapter on top of it, and run it on a free 15 or 16 GB notebook GPU from Kaggle or Google Colab. Unsloth, an open-source library, publishes ready-made notebooks for both that do the setup for you. What you cannot do for free is full fine-tuning or training a 70B model; those need far more GPU memory than any free tier gives.

Every figure below was read on the vendor's page on 2026-10-26. Rows that link an offer page are in our verified catalog; Google Colab is not yet, so its row links Google's page. To pick a GPU, a host to serve the result and a free API as fallback in one go, use the [fine-tune stack](https://aifree.dev/stack/finetune).

## Free GPUs for fine-tuning at a glance

| Option | What is free | GPU memory | Session limit | The catch |
| --- | --- | --- | --- | --- |
| [Kaggle notebooks](https://aifree.dev/offer/kaggle-free-gpu-tpu) | 30 GPU hours a week, sometimes more; 20 TPU hours | NVIDIA P100 (16 GB) or 2x T4 | 12 hours | Phone verification unlocks the GPU; quota resets weekly |
| [Google Colab](https://research.google.com/colaboratory/faq.html) | GPU and TPU runtimes, limits not published | About 15 GB on the free GPU | Up to 12 hours | GPU access is "heavily restricted" and varies; idle runtimes time out |
| [Lightning AI](https://aifree.dev/offer/lightning-ai-free-plan) | Up to 30 credits, about 75 hours on a T4 | T4 16 GB, L4 24 GB and up | Free Studio restarts every 4 hours | Credits expire after 12 months |
| [Paperspace Gradient](https://aifree.dev/offer/paperspace-gradient-free-tier) | Basic free GPU notebooks, 5 GB storage | Basic instances only | 12 hours, auto-shutdown | Public projects only |
| [Hugging Face ZeroGPU](https://aifree.dev/offer/hugging-face-zerogpu-spaces) | 5 GPU minutes a day | Half or full RTX Pro 6000 | Per call | For running a demo, not for training |

Source: [Kaggle efficient GPU usage](https://www.kaggle.com/docs/efficient-gpu-usage), [Colab FAQ](https://research.google.com/colaboratory/faq.html), [Lightning AI pricing](https://lightning.ai/pricing), and our offer pages linked above, checked 2026-10-26. The [free GPU quota tracker](https://aifree.dev/tools/free-gpu-quotas) works out the hours you have left this week.

## How much GPU memory you need

Fine-tuning a model changes it; with LoRA you freeze the original weights and train a small set of extra "adapter" weights instead, which needs far less memory ([what LoRA is](https://aifree.dev/explain/lora)). QLoRA does the same with the frozen model loaded in 4-bit. Unsloth's requirements page lists the minimum VRAM for each:

| Model size | QLoRA (4-bit) | LoRA (16-bit) | Fits a free 15-16 GB GPU? |
| --- | --- | --- | --- |
| 3B | 3.5 GB | 8 GB | Yes, both |
| 7B-8B | 5-6 GB | 19-22 GB | QLoRA only |
| 14B | 8.5 GB | 33 GB | QLoRA only |
| 27B | 22 GB | 64 GB | No: Lightning credits on an L4 or larger, or paid Colab |
| 70B | 41 GB | 164 GB | No |

Unsloth calls these "the absolute minimum": long examples and large batches need more. When you run out of memory, it says, the usual cause is a batch size set too high; set it to 1, 2 or 3. Read [why GPU memory decides what you can run](https://aifree.dev/explain/vram) if the numbers are new to you.

Source: [Unsloth requirements](https://unsloth.ai/docs/get-started/fine-tuning-for-beginners/unsloth-requirements), checked 2026-10-26.

## Step 1: decide whether fine-tuning is the right tool

Fine-tuning teaches a model a format, a tone or a narrow task: answer in your company's JSON schema, write like your support team, classify tickets into your categories. It is a poor way to teach facts that change, such as a product catalog or this week's prices; retrieval does that better and cheaper ([RAG or fine-tuning?](https://aifree.dev/explain/rag-vs-fine-tuning)). If a good prompt with a few examples already gets you most of the way, try that first: it costs nothing to change.

## Step 2: prepare a dataset

Unsloth's guide says a dataset usually has two columns, question and answer, and that its quality and size "will largely reflect the end result". Start with a few hundred clean examples and add more only if the test set shows the model still gets the task wrong. Write them yourself, export them from real conversations you are allowed to use, or generate drafts with a model and fix them by hand. Keep 10% aside to test with. Upload the file as a Kaggle dataset or to your Google Drive.

Start from an instruct model rather than a base model: Unsloth recommends instruct models because they take chat-formatted data directly and need less of it.

## Step 3: run a free notebook

1. Open Unsloth's notebooks page and pick a notebook for a model of 14B or less; each has a Kaggle and, for most, a Colab version.
2. On Kaggle, verify your phone number in your account settings, then turn on a GPU under **Settings → Accelerator**. On Colab, choose **Runtime → Change runtime type** and pick a GPU.
3. Replace the sample dataset with yours, keeping the column names the notebook expects.
4. Leave the defaults on the first run. Unsloth recommends QLoRA to start and 1 to 3 epochs "to avoid overfitting".
5. Click **Run all** and watch the training loss. Unsloth says a loss around 0.5 to 1.0 is often a good sign; a loss near 0 can mean the model memorized your data.
6. Chat with the result on your held-out examples before you trust it.

Keep the first run small (a 3B-8B model, a few hundred examples, one epoch) so it finishes inside one Kaggle or Colab session. Save checkpoints to disk or to the Hugging Face Hub as you go: a Colab runtime can be stopped early, and a Kaggle session ends at 12 hours.

Source: [Unsloth notebooks](https://unsloth.ai/docs/get-started/unsloth-notebooks), [Unsloth fine-tuning guide](https://unsloth.ai/docs/get-started/fine-tuning-llms-guide), checked 2026-10-26.

## Step 4: save and run your model

The notebook ends with the trained adapter, a small set of weights that sits on top of the base model. You can:

- **Push it to the Hugging Face Hub** with your free account and load it on top of the base model anywhere.
- **Export a GGUF file** and run it on your own computer with Ollama, llama.cpp or LM Studio, as Unsloth's guide describes; see [how to run AI locally for free](https://aifree.dev/learn/run-ai-locally-free).
- **Host a demo** on a Hugging Face Space with [ZeroGPU](https://aifree.dev/offer/hugging-face-zerogpu-spaces): 5 GPU minutes a day for free accounts, enough for a few people to try it.

The [fine-tune stack](https://aifree.dev/stack/finetune) adds a free host for the app around your model and a free LLM API to fall back on when the demo GPU runs out.

## When the free GPUs are not enough

- **Lightning AI** starts every account with free credits, up to 30 in total, which its pricing page turns into about 75 hours on a T4 or 31 on a 24 GB L4. The L4's 24 GB is just above Unsloth's 22 GB QLoRA minimum for a 27B model.
- **Anyscale** gives [$100 of credit](https://aifree.dev/offer/anyscale-free-signup-credits) for CPU and GPU compute on Ray.
- **Students** at U.S. universities get [$20 of Thunder Compute credit](https://aifree.dev/offer/thundercompute-student-credit); academic researchers can apply for the [Lambda Research Grant](https://aifree.dev/offer/lambda-research-grant) or [Nebius research grants](https://aifree.dev/offer/nebius-research-grants).
- **Startups** have larger programs: see [AI startup credits](https://aifree.dev/learn/ai-startup-credits).

Colab Pro for Education, which gave U.S. students a free year of Colab Pro, is closed to new signups.

## Limits and the catch

- **Free GPUs are shared.** Colab does not publish its limits and says they "vary over time"; Kaggle's 30 hours is a weekly quota. Turn the GPU off while you edit, so idle time does not eat the quota.
- **QLoRA has a ceiling.** Free GPUs top out around 14B parameters in 4-bit; full fine-tuning of even a 3B model needs more memory than they have.
- **A fine-tuned model is still a language model.** It learns style and format more reliably than facts, and it can state things confidently that your data never said.
- **Check the base model's license** before you share or sell what you trained ([what open weights means](https://aifree.dev/explain/open-weights)).
- **Limits change.** We re-check vendor pages monthly; the date at the top of this page is our latest check.

## Offers in this guide

- [Kaggle Free GPU and TPU Notebooks](https://aifree.dev/offer/kaggle-free-gpu-tpu.md): 30 hours/week, no card. Free Kaggle notebooks: 30 hours/week of GPU and 20 hours/week of TPU
- [Lightning AI Free Plan](https://aifree.dev/offer/lightning-ai-free-plan.md): 30 credits, no card. Up to 30 free credits (about 80 GPU hours) and 1 free Studio
- [Hugging Face ZeroGPU Free GPU Access on Spaces](https://aifree.dev/offer/hugging-face-zerogpu-spaces.md): 5 minutes/day, no card. ZeroGPU dynamically allocates NVIDIA RTX Pro 6000 Blackwell GPUs to Gradio
- [Paperspace Gradient Free GPU Notebooks](https://aifree.dev/offer/paperspace-gradient-free-tier.md): Free tier, card. Free basic GPU notebooks and 5 GB storage on Paperspace
- [Anyscale $100 Free Signup Credit](https://aifree.dev/offer/anyscale-free-signup-credits.md): $100, no card. $100 in Anyscale credits for CPU and GPU compute on Ray, no card
- [Thunder Compute Student Credit](https://aifree.dev/offer/thundercompute-student-credit.md): $20, no card. $20 in free GPU credit for US university students

## Frequently asked questions

### Can I fine-tune an LLM for free?

Yes, for small models. With QLoRA, a 7B or 8B model needs about 5 to 6 GB of GPU memory and a 14B model about 8.5 GB, which fits the free 15-16 GB GPUs in Kaggle notebooks (30 hours a week) and Google Colab.

### Is Kaggle or Colab better for fine-tuning?

Kaggle publishes its quota: 30 GPU hours a week and 12-hour sessions after phone verification. Colab is free too, but Google does not publish its limits and says GPU access on the free tier is heavily restricted, so a long run can stop early.

### What is Unsloth?

Unsloth is an open-source library for fine-tuning open models with less GPU memory. It publishes free notebooks for Kaggle and Colab and a table of the minimum VRAM for QLoRA and LoRA at each model size.

### Can I fine-tune a 70B model for free?

No. Unsloth lists 41 GB of VRAM as the minimum for QLoRA on a 70B model, more than any free notebook GPU. Use a smaller model, or credits such as Lightning AI or a research grant.

### Should I fine-tune or use RAG?

Fine-tune to change format, tone or a narrow task; use retrieval (RAG) to give a model facts that change, such as documents or prices. Many projects need only a better prompt.

## Sources

- https://www.kaggle.com/docs/efficient-gpu-usage
- https://research.google.com/colaboratory/faq.html
- https://lightning.ai/pricing
- https://unsloth.ai/docs/get-started/fine-tuning-for-beginners/unsloth-requirements
- https://unsloth.ai/docs/get-started/unsloth-notebooks
- https://unsloth.ai/docs/get-started/fine-tuning-llms-guide
- https://github.com/unslothai/unsloth

HTML page: https://aifree.dev/learn/fine-tune-llm-free
