Building your first Qollab projectLesson 5 of 5

Bring your own code into Qollab

Move a circuit you wrote locally into Qollab: the Qiskit carries over, the provider setup does not.

If you already write Qiskit locally, you do not have to start over in the browser. Paste your circuit into a Qollab project and run it. One thing changes: how you reach a backend.

Your circuit carries over

The Qiskit you write is standard, so the part that builds your circuit works unchanged: QuantumCircuit, gates, measurements, transpilation. Paste it into a project's Code tab, the same editor from Use the Code Playground.

Swap the provider setup for the pre-created backend

Locally, you set up a provider with an API key and asked it for a backend:

# Local: you manage the provider and key yourself
from qiskit_ionq import IonQProvider

provider = IonQProvider(token="your_api_key")
backend = provider.get_backend("simulator")

On Qollab you delete all of that. A backend is already created for you, and you choose where it runs in the Select QPU dialog when you press Run. There are no keys to manage:

# Qollab: backend is pre-created; just run against it
job = backend.run(circuit, shots=100)
print(job.result().get_counts())

Run and share

Press Run, pick a simulator (free) or real hardware (credits), and read your results in the console. Your project is now shareable, forkable, and one click from real hardware, without any local setup. Publishing and versions covers making it public.

That is the course. You can create, run, fork, and bring your own code to Qollab.

Stay in the loop.

Get the latest tutorials, demos, and project showcases straight to your inbox. No noise, just the good stuff.