DEV Community

Evan Lin
Evan Lin

Posted on • Originally published at evanlin.com on

VS Code Plugin for Colab Released by Google

Connecting to a new Colab server and executing a code cell

Background

Google Colab is a service I really like. You can quickly use a GPU (or even a TPU) online through the Jupyter Notebook interface. Many things that require a lot of computing resources can be executed very quickly on a remote machine.

I often use it to try out some models, although I often have to wait in line to get a machine.

image-20251114155345861

Pain Points of Using Colab

Although using Google Colab machines is very convenient, there are some more troublesome aspects of online editing:

  • Unable to use Code Assist Tools like Copilot to help me auto-complete some code.
  • Unable to run Gemini CLI Code Assist to help me write more tests or help me think about applications.

Colab for VS Code Plugin

But now the Colab VS Code Extension can finally be used on the VS Code Plugin. You can find the official Plugin released by "Colab" directly.

Code 2025-11-14 15.55.03

The installation process is very simple and fast.

Connecting to Colab

Code 2025-11-14 15.23.10

If you want to connect, you can choose Colab when selecting the Kernel to connect remotely.

Code 2025-11-14 15.23.16

Here you can also quickly connect, or find the server you connected to last time.

Code 2025-11-14 15.23.22

This is where it gets exciting, you can try to find a TPU (no guarantee of getting in line) to use.

That's it.

Practical Application:

Code 2025-11-14 15.54.52

This is more like it!! After Vibe Coding appeared, we are more and more used to Vibe Coding. But if you need to debug Step by Step, or want to run some calculations that can only be run on large machines. You really still need Colab to help, but if you also want the assistance of Gemini CLI, perhaps the Colab VS Code Extension is your indispensable good partner.

Things to Note at the Moment

Since the Colab VS Code Plugin is still under development, some google.colab features that can be used on the Colab Web UI are currently not available in VS Code. Here are some of the main limitations:

  • auth.authenticate_user(): The authentication URL will appear in the menu and cannot be clicked directly. It is recommended to use the Python Cloud Client Library.
  • drive.mount(): Currently unable to mount Google Drive, you can use the Drive Python API to access files.
  • files.download() / files.upload(): The native file upload and download functions are not available, but you can achieve the same effect through IPyWidget.
  • userdata.get(): Currently returns an error, you temporarily need to copy the secret value from the Colab Web UI to the notebook.

Although there are these limitations, the Colab VS Code Plugin still greatly improves the development experience. Especially for developers who are used to using VS Code and various AI Coding Assistants, it is definitely a good tool worth trying!

References


Enter fullscreen mode Exit fullscreen mode

Top comments (0)