New Tool Radar

Local AI

How to Copy an Ollama Model Under a New Name with ollama cp

Duplicate a downloaded model under a new name with ollama cp, so you can experiment on the copy while the original stays untouched, with no second download.

Schematic diagram with three steps: the original llama3.2 downloaded once, copy it with ollama cp to my-llama3-variant, then ollama list shows both names.

Before you change a model — a new system prompt, different parameters, a custom Modelfile — copy it first. ollama cp creates a local copy of a model under a new name without downloading anything again, and both names point to the same files on disk, so the copy costs no extra disk space. The original stays exactly as it was, and every experiment happens on the copy.

Copy first, then change the copy

The command takes a source name and a destination name. For a fictional practice copy of llama3.2:

ollama cp llama3.2 my-llama3-variant

That is the whole step. It is different from creating a custom model with a Modelfile, which changes the model’s settings: ollama cp changes nothing about the model, only its name. It is the safe first step before a Modelfile edit, because the original remains available to fall back to. The same copy operation exists in the JavaScript library as ollama.copy, with a source and a destination.

Try it: three checks that the copy worked

Step Command What you should see
1. Copy the model ollama cp llama3.2 my-llama3-variant The command finishes without an error
2. List your models ollama list Both llama3.2 and my-llama3-variant are listed
3. Run the copy ollama run my-llama3-variant A chat prompt opens for the copy, and the original is still listed separately

Expected result. We checked the Ollama CLI reference and the JavaScript library README. We did not copy a model on this machine.

Limits

A copy is not a backup of the model file in the usual sense: both names point to the same stored files, so deleting the files removes both names, while ollama rm on one name removes only that name. A copy also inherits everything about the original, including its license and its parameters, so copying does not make a model yours to redistribute. If you then build a custom model from the copy with a Modelfile, the original is still untouched, which is the point of copying first. We did not test any of this ourselves.

Sources

See all