<!-- mobian-agent-page publisher="dailydev" canonical="https://daily.dev/posts/golang-client-for-ethereum-json-rpc-api-fudprwpvl" -->

---
title: Golang client for ethereum json rpc api | daily.dev
description: package main import ( "fmt" "log" "github.com/onrik/ethrpc" ) func main () { client := ethrpc . New ( "http://127.0.1:8545" ) version , err := client ....
canonical: https://daily.dev/posts/golang-client-for-ethereum-json-rpc-api-fudprwpvl
twitter:card: summary_large_image
twitter:site: @dailydotdev
og:type: website
og:site_name: daily.dev
og:title: Golang client for ethereum json rpc api | daily.dev
og:description: package main import ( "fmt" "log" "github.com/onrik/ethrpc" ) func main () { client := ethrpc . New ( "http://127.0.1:8545" ) version , err := client ....
og:url: https://daily.dev/posts/golang-client-for-ethereum-json-rpc-api-fudprwpvl
og:image: https://api.daily.dev/og/posts/FUDPRWpVL.png
og:image:alt: Golang client for ethereum json rpc api
og:image:width: 1200
og:image:height: 630
og:locale: en
---

> ## Documentation Index
> Fetch the complete documentation index at: https://daily.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# Golang client for ethereum json rpc api

**[Golang Example](https://daily.dev/sources/golangexample)** · 1 min read · 0 upvotes · 0 comments

## Summary

package main import ( "fmt" "log" "github.com/onrik/ethrpc" ) func main () { client := ethrpc . New ( "http://127.0.1:8545" ) version , err := client . Web3ClientVersion () if err != nil { log . Fatal ( err ) } fmt . Println ( version ) // Send 1 eth txid , err = client . EthSendTransaction (ethrPC. Eth1 ( T { From : "0x6247cf0412c6462da2a51d05139e2a3c6c630f0a" , To : "

## Full article

daily.dev links to this article rather than hosting it. Read it at the original source: <https://golangexample.com/golang-client-for-ethereum-json-rpc-api/>

---

Tags: [#backend](https://daily.dev/tags/backend), [#crypto](https://daily.dev/tags/crypto), [#golang](https://daily.dev/tags/golang), [#logging](https://daily.dev/tags/logging)

[View this post on daily.dev](https://daily.dev/posts/golang-client-for-ethereum-json-rpc-api-fudprwpvl)

```json
{"@context":"https://schema.org","@graph":[{"@type":"Organization","@id":"https://daily.dev/#organization","name":"daily.dev","url":"https://daily.dev","logo":{"@type":"ImageObject","url":"https://daily.dev/apple-touch-icon.png","width":180,"height":180},"sameAs":["https://twitter.com/dailydotdev","https://github.com/dailydotdev","https://www.linkedin.com/company/daily-dev-ltd"]},{"@type":"WebSite","@id":"https://daily.dev/#website","url":"https://daily.dev","name":"daily.dev","publisher":{"@id":"https://daily.dev/#organization"},"potentialAction":{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https://daily.dev/search?q={search_term_string}"},"query-input":"required name=search_term_string"}}]}
{"@context":"https://schema.org","@type":"TechArticle","headline":"Golang client for ethereum json rpc api","url":"https://daily.dev/posts/golang-client-for-ethereum-json-rpc-api-fudprwpvl","mainEntityOfPage":{"@type":"WebPage","@id":"https://daily.dev/posts/golang-client-for-ethereum-json-rpc-api-fudprwpvl"},"datePublished":"2021-12-21T16:10:56.397Z","dateModified":"2021-12-25T02:15:30.817Z","description":"package main import ( \"fmt\" \"log\" \"github.com/onrik/ethrpc\" ) func main () { client := ethrpc . New ( \"http://127.0.1:8545\" ) version , err := client ....","image":"https://media.daily.dev/image/upload/f_auto,q_auto/v1/posts/eb61c246abe5a5bfaa96b005adf95c1e","thumbnailUrl":"https://media.daily.dev/image/upload/f_auto,q_auto/v1/posts/eb61c246abe5a5bfaa96b005adf95c1e","isAccessibleForFree":true,"articleSection":"Golang Example","inLanguage":"en","publisher":{"@type":"Organization","name":"daily.dev","url":"https://daily.dev","logo":{"@type":"ImageObject","url":"https://daily.dev/apple-touch-icon.png","width":180,"height":180}},"author":{"@type":"Organization","name":"Golang Example","logo":"https://media.daily.dev/image/upload/t_logo,f_auto/v1/logos/a2ba12f3f1184e329cff6fc41dbb80ab","url":"https://daily.dev/sources/golangexample"},"commentCount":0,"discussionUrl":"https://daily.dev/posts/golang-client-for-ethereum-json-rpc-api-fudprwpvl","interactionStatistic":[{"@type":"InteractionCounter","interactionType":{"@type":"LikeAction"},"userInteractionCount":0},{"@type":"InteractionCounter","interactionType":{"@type":"CommentAction"},"userInteractionCount":0}],"keywords":"backend,crypto,golang,logging","timeRequired":"PT1M"}
{"@context":"https://schema.org","@type":"BreadcrumbList","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https://daily.dev"},{"@type":"ListItem","position":2,"name":"Golang Example","item":"https://daily.dev/sources/golangexample"},{"@type":"ListItem","position":3,"name":"Golang client for ethereum json rpc api"}]}
```

