Skip to content

Hardhat VS Code extension

Hardhat has extensions for Visual Studio Code, Cursor, and Antigravity. These extensions add language support for Solidity and integration with Hardhat and Foundry projects.

  • Code completions: autocomplete for contract instances, globally available variables, built-in types, and import directives
  • Navigation: go to definition, go to type definition, and go to references
  • Symbol renames: rename identifiers across the codebase
  • Hover help: type and signature information on hover
  • Inline validation: compiler warnings and errors as you type
  • Code actions: quick fixes like adding visibility modifiers, specifying data locations, implementing interface functions, constraining mutability, fixing address checksums, and more
  • Formatting: document formatting for Solidity files

Learn more about it on its Visual Studio Code Marketplace page or Open VSX Registry page.

To use the extension in Visual Studio Code, please click this link to install it.

To use the extension in Cursor, please click this link to install it.

To use the extension in Antigravity, please click this link to install it.

To use the Language Server that powers the extension in Vim and Neovim, please refer to the documentation in the @nomicfoundation/solidity-language-server npm package.