Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Install MLflow with pip install mlflow, start a local tracking server on port 5000, and log your first run from Python. For local development, MLflow’s environment guide recommends SQLite; use a shared server, Docker Compose, or Databricks Managed MLflow when you need collaboration or managed infrastructure.

Choose where MLflow will store runs

MLflow Tracking records experiment metadata—such as parameters, metrics, and run details—and can store model artifacts. The tracking URI determines where tracking data is written, so choose a backend before connecting multiple users or machines.

Option Setup and persistence Collaboration, artifacts, and ownership
Local file store Fastest to try; when no tracking URI is specified, MLflow can use local file storage and create an mlruns directory. The environment guide says this backend is in Keep-the-Light-On mode. Best suited to simple work on one machine, not a shared team setup. Move toward a database for ongoing local development.
SQLite A lightweight persistent database; MLflow’s environment guide recommends sqlite:///mlflow.db for quickstarts and local development. Useful for local experiments. It does not by itself provide a shared, secured team service or remote artifact store.
Self-hosted server Run an MLflow tracking server and configure a database backend and artifact storage as needed. Provides a shared UI and API, but your team owns operations and security configuration. Production guidance uses a remote artifact root such as s3://my-mlflow-bucket/artifacts.
Docker Compose The official Compose flow starts MLflow with PostgreSQL and MinIO and exposes port 5000. A reproducible fuller local stack with a database and object store; you still operate the stack and should configure access appropriately.
Databricks Managed MLflow Uses Databricks workspace setup and authentication rather than a server you operate yourself. Managed infrastructure and workspace integration; availability and use are subject to Databricks account and program terms.

For the shortest path, use SQLite and a local server. Use local file storage only when the simplicity of a one-machine experiment matters more than a database-backed setup. Choose a shared or managed option when collaborators need access to the same tracking service.

Install MLflow and start the local UI

  1. Install the Python package in the environment where you will run your training code: pip install mlflow.

    Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
  2. Start a tracking server with SQLite as its backend:

    mlflow server --backend-store-uri sqlite:///mlflow.db --port 5000

    Leave this process running while you use the UI or send tracking requests. The SQLite URI follows MLflow’s environment-guide recommendation for quickstarts and local development.

  3. Open http://localhost:5000 in a browser on the same machine. The server listens on port 5000 unless you choose another port.

If you omit a tracking URI in a simple local script, MLflow can create an mlruns file-store directory instead. That is convenient for trying the APIs, but the environment guide describes file storage as being in Keep-the-Light-On mode and recommends moving toward a database.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Log and inspect a first experiment

MLflow’s Tracking Quickstart describes its goal as “to provide a quick guide to the most essential core APIs of MLflow Tracking.” A minimal workflow is to name an experiment, enable supported framework autologging, train a model, then inspect the recorded run.

  1. In your Python training script, select the local server and create or select an experiment:

    import mlflow
    import mlflow.sklearn
    
    mlflow.set_tracking_uri("http://localhost:5000")
    mlflow.set_experiment("MLflow Quickstart")
    mlflow.sklearn.autolog()
  2. Run your usual scikit-learn training code in the same script after enabling autologging. For supported frameworks, autologging can capture parameters, metrics, model artifacts, and metadata without requiring you to log each item manually.

  3. Return to the UI at http://localhost:5000, open the MLflow Quickstart experiment, and select the run to review its recorded details and artifacts.

    Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

The tracking server must be running at the URI your code uses. If you change the server port or host, update the URI accordingly.

Load a logged model for inference

When autologging or your own logging code has recorded a model, load it through MLflow’s generic pyfunc interface using the run’s model URI. The exact URI depends on the run ID and artifact path shown for that run.

import mlflow.pyfunc

model = mlflow.pyfunc.load_model("runs:/<run_id>/model")
predictions = model.predict(input_data)

Replace <run_id> with the actual run ID, and use the model artifact path recorded by your run if it differs from model. Provide input in the format expected by the logged model.

Connect code to a remote tracking server

For a shared MLflow server, point your code at its reachable HTTP address rather than assuming localhost. For example, replace the host below with the server address supplied by its administrator:

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
import mlflow

mlflow.set_tracking_uri("http://<server-host>:5000")

Alternatively, configure the tracking URI through the environment variable before running the script:

export MLFLOW_TRACKING_URI=http://<server-host>:5000

The tracking URI directs experiment metadata to that server. A remote deployment also needs artifact storage that the server and users can access; production self-hosting guidance shows a remote artifact root such as s3://my-mlflow-bucket/artifacts. The team operating a self-hosted service is responsible for its operations and security configuration.

Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Support on Ko-Fi

When Docker Compose or Databricks is a better fit

Use Docker Compose for a reproducible local stack

The official MLflow Compose flow brings up MLflow with PostgreSQL and MinIO and exposes port 5000. Choose it when you want a fuller, repeatable local environment rather than a single SQLite-backed server. Follow the official Compose setup for its files and commands, then connect clients to the exposed server address.

Use Databricks Managed MLflow for workspace-managed infrastructure

Databricks documents Managed MLflow with workspace setup and Databricks authentication. It can suit teams that want MLflow integrated with their Databricks workspace without operating the tracking infrastructure themselves. The workspace and account terms govern access; this is not simply a public local server.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Use a self-hosted service for production control

Self-hosting gives an organization control over its shared tracking endpoint and storage choices, but it also means owning deployment, security, database, and artifact-storage decisions. MLflow’s self-hosting guidance includes remote artifact roots such as S3 and an official Helm chart for Kubernetes.

Common setup problems

Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.