
Product
Introducing Reports: An Extensible Reporting Framework for Socket Data
Explore exportable charts for vulnerabilities, dependencies, and usage with Reports, Socket’s new extensible reporting framework.
web3-react-hooks
Advanced tools
A set of convenience hooks for web3 actions in react.
Install using npm or yarn:
npm i -S web3-react-hooks
This module has react as a peer dependency, since it provices react hooks 🤷♂️
Example usage:
import React from 'react'
import { useAddress, useENS } from 'web3-react-hooks'
export default function UserProfile() {
const address = useAddress()
const ens = useENS()
return <p>Welcome back { address.slice( 0, 10 ) }! { ens ? `Your ENS name ${ ens } looks good!` : `You should get a fancy ENS ;)` }</p>
}
All hooks have jsdoc declarations you can use to get more details on what they do.
Useful frontend hooks
Chain/wallet
0x01 is Ethereum MainnetGeneric interfaces
ethers.js provider instance, see the ethers provider documentation for what you can do with itFor a more elaborate demo, run npm start inside the demo directory.
Do you need a hook not in this list? Suggest a feature here.
Pull requests are welcome! If you want to implement backwards-incompatible changes please check in first.
FAQs
React hooks that interact with web3 systems like Metamask.
We found that web3-react-hooks demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Product
Explore exportable charts for vulnerabilities, dependencies, and usage with Reports, Socket’s new extensible reporting framework.

Product
Socket for Jira lets teams turn alerts into Jira tickets with manual creation, automated ticketing rules, and two-way sync.

Company News
Socket won two 2026 Reppy Awards from RepVue, ranking in the top 5% of all sales orgs. AE Alexandra Lister shares what it's like to grow a sales career here.