Synopsis
Description
Thepush command uploads a local model to a registry (default: Ollama’s public registry at ollama.com). This allows you to share custom models with others or back them up to a remote location.
To push models to ollama.com, you must first sign in using ollama signin.
Arguments
Name of the model to push. Must include namespace for public registries.Format:
namespace/model:tagExamples:myusername/custom-llama:latestmyusername/fine-tuned-model:v1
Options
Allow pushing to registries without HTTPS
Model Naming
Models must follow this naming convention for public registries:- namespace: Your username or organization (required for ollama.com)
- model: Your model name
- tag: Optional version tag (defaults to
latest)
Examples
Push to Ollama.com
First, sign in:Push with Tag
Push a specific version:Push to Custom Registry
Push to a private or custom registry:Push to Local Registry
Push to a local insecure registry:Prerequisites
Authentication
For ollama.com, you must authenticate first:Model Ownership
You can only push models to namespaces you own. Attempting to push to someone else’s namespace will result in an error:Progress Output
During upload, you’ll see progress for each layer:- Layer digest (first 12 characters)
- Percentage complete
- Bytes uploaded / total size
Model Layers
The following layers are pushed:- Model weights
- Configuration and metadata
- Template
- Parameters
- System message
- License
Bandwidth Considerations
Uploading large models can take significant time:| Model Size | Upload Time (10 Mbps) | Upload Time (100 Mbps) |
|---|---|---|
| 7B params | ~45 minutes | ~5 minutes |
| 13B params | ~1.5 hours | ~9 minutes |
| 34B params | ~4 hours | ~25 minutes |
| 70B params | ~8 hours | ~50 minutes |
Actual upload times vary based on network speed and server load.
Environment Variables
Ollama server address to read the model from
Exit Codes
0- Success, model pushed completely1- Error occurred (authentication, network, permissions, etc.)
Troubleshooting
Not Authorized
Model Not Found
Network Timeout
Invalid Model Name
Sharing Your Model
After successfully pushing to ollama.com:- Your model will be available at:
https://ollama.com/{namespace}/{model} - Others can pull it with:
ollama pull {namespace}/{model} - You can add a README and description on the website
Privacy
For private models:- Use a private registry
- Or keep models local and share via other means
Related Commands
ollama signin- Sign in to ollama.comollama create- Create a model to pushollama pull- Pull a model from a registryollama list- List local models available to pushollama show- Show model details before pushing