Speed Up Python Package Installation: A Guide to Using pip Mirrors

Speed Up Python Package Installation: A Guide to Using pip Mirrors

When installing Python packages with pip, the default source is the Python Package Index (PyPI). But sometimes, due to network restrictions, slow speeds, or access issues, it's better to use a mirror — a replica of PyPI hosted by another provider.
This guide will show you how to use pip mirrors both temporarily and permanently.

Why Use a pip Mirror?

  1. Speed up installation by using a nearby mirror
  2. Provide redundancy in case PyPI is down
  3. Improve reliability behind firewalls or in restricted regions

Use a Mirror Temporarily (One-Time)

You can specify a mirror directly in the `pip install` command:
  1. pip install -i https://<mirror_url>/simple <package_name>
Example (Tsinghua Mirror)
If you run into SSL issues, add --trusted-host:
  1. pip install -i https://pypi.tuna.tsinghua.edu.cn/simple --trusted-host pypi.tuna.tsinghua.edu.cn requests

​Use a Mirror with Requirements File

  1. pip install -i https://pypi.tuna.tsinghua.edu.cn/simple -r requirements.txt

Trusted Public pip Mirrors

    • Related Articles

    • Billing & Payment Guide

      A. Payment & Credit Management 1. Depositing Credits via Stripe Follow these steps to deposit credits into your GreenNode account: Step 1: Accessing the Credit Page Log in: Access the GreenNode AI Platform by navigating to ...
    • Import a Model Registry using vLLM

      Step 1: Accessing the Model Registry Log in to your GreenNode AI Platform account and navigate to the Model Registry Dashboard. Find and click on the "Import a model registry" button. Step 2: Import a Model Registry Location & Model registry name: ...
    • Import a Model Registry using NVIDIA NIM

      Step 1: Accessing the Model Registry Log in to your GreenNode AI Platform account and navigate to the Model Registry Dashboard Model Registry Dashboard at: . Find and click on the "Import a model registry" button. Step 2: Import a Model Registry ...
    • Import a Model Registry using SGLang

      Step 1: Accessing the Model Registry Log in to your GreenNode AI Platform account and navigate to the Model Registry Dashboard. Find and click on the "Import a model registry" button. Step 2: Import a Model Registry Location & Model registry name: ...
    • Import a Model Registry using Triton Server

      Model Preparation Since our AI Platform only accesses models from a Network Volume, you must first create a Network Volume. Pull your model from local file systems or cloud storage (AWS S3, Azure Blob, or GCS) into the Network Volume. Ensure the ...