How to Add a Bitcoin Donate Button to Your WordPress Site

Updated on December 10, 2017

Also in that time, it’s risen to a sky-high exchange rate of $1242 per bitcoin  and also plummeted to its current $14940.10 exchange rate (and it’s changing every minute). As you could probably guess, the peer-to-peer currency isn’t exactly the epitome of stability.

Whether you think Bitcoin is a beauty or a beast, it’s obviously here to stay for the time being. If you’re enthralled by the idea of a cyberspace currency, and would like to learn how to add a Bitcoin donate button into your WordPress site, then you’re in the right place. But first, a few words about exactly who that new kid on the currency block really is.

What Is Bitcoin?

In short, few really understand how Bitcoin works.

But there are a few things we do know. For one, it’s a completely virtual currency, which means that you can’t pay Bitcoin in bills, notes, or even a real coin. All payments occur in the cyberspace. Secondly, there’s a huge amount of it, with the dollar equivalent of over $1.5 billion in Bitcoin circulating today — numerous transactions take place every minute.

You can pay for anything and everything with Bitcoin as long as the merchant in question accepts it. That includes marketing services, website memberships, car rentals, and — ahem, other stuff.

And, in light of this tutorial, you can also use Bitcoin to receive donations on your WordPress blog (or any website, for that matter). Here’s how.

Step 1. Create Your Bitcoin Wallet & BitPay Account

The first thing you need to do is set up your Bitcoin wallet — this is where all the bitcoins you receive will be stored. BlockChain is the most popular Bitcoin wallet service, due to the fact that it’s a free web-based app you can log into anytime from anywhere.

Head over there, select Create My Free Wallet, and fill in the details required on the next page.


WRITE YOUR PASSWORD DOWN — unlike nearly every other Internet service, you won’t be able to recover your BlockChain password if you ever forget it. Furthermore, any bitcoins you might have owned in that account will then be lost forever.


Forget your password? Sorry, bud.

After signing up, a verification e-mail will be sent to the address you provided. Click on the confirmation link provided. Once that loads, click on your unique login link, supply your password (the identifier will automatically be entered), and hit Open Wallet.


Verify your e-mail address, and click the login link.


When you click on your login link, you’ll be redirected here. Your identifier will automatically be filled in — just key in your password.

Once you login, you’ll be hit with a dashboard that supplies your account’s current information: the number of bitcoins you have, the dollar equivalent, and your Bitcoin address: an alphanumeric code (not confidential) people use to send money to you.


Now, head over to BitPay and create an account. Each account is manually activated, so you’ll have to wait a few hours after signing up to be approved as a member (you’ll be sent an e-mail notification when that happens).

If you’re a mite confused about the difference between Bitcoin, Blockchain, and BitPay, and why you need to sign up for all of them, think of it this way: Bitcoin is the money, Blockchain is your bank, and BitPay is essentially the same thing as PayPal for Bitcoin an e-payment system. Just like centralized banks and PayPal, BlockChain and BitPay have their own competitors and alternatives. But for the most part, they’re the most popular choices.

Step 2. Creating Your Bitcoin Donate Button

Following your BitPay account approval, login to your BitPay dashboard. Click on the Accept Bitcoin link in the top navigational menu (extreme left).

Select the eCommerce option, and then Accept Donations on the next page.


Here’s where you configure your Bitcoin donate button. You can pre-set the donation amount (e.g. $10) for that specific button, or you can allow donors to choose their own donation amount (my personal choice would be the latter option).

After selecting pre-set or custom donations, a few fields will pop up. Fill out the Merchant Name (your personal name or website domain), set a short description, and if you went with a pre-set donation amount, use the provided text box to establish that amount.


You can also customize the URL donors are sent to after completing a transaction (a thank-you page, for example). Lastly, enter a e-mail address to be notified every time a donation is made.

Once you’re all done with that, hit “Generate” to generate the HTML code for your Bitcoin donate button. You can choose from three default sizes: small, medium, and large. Copy the code provided and store it on your computer in a Notepad document.


Copy this code.

Step 3. Inserting Your Donate Button in WordPress

Almost there, one last step: inserting the button code into your website. But you can’t just insert the generated HTML into the text editor of a page — you need to first ensure that it will work seamlessly with WordPress. To do that, create a shortcode in your theme’s functions.php file (Appearance > Editor > Functions.php) by copy/pasting the following code:

[php]function wpb_bitcoin_button() {
[the bitpay code generated in step 2 goes here]
return ob_get_clean();

add_shortcode(‘bitcoinbutton’, ‘wpb_bitcoin_button’);[/php]


Here’s what that looks like in my theme editor.

Once you’ve added this code into your functions.php and updated the theme file, you can now use the shortcode [bitcoinbutton] whenever you’d like to display a Bitcoin donate button on your website. Congratulations! You’re all set to start receiving user donations via the world’s most exciting currency!

Before you leave, do me a favor and answer me this question: what’s your opinion of Bitcoin? Is it here to stay — permanently — or is it just another passing fad?

Leave your comment below (psst! Don’t forget to use the social sharing buttons, either)!

*Featured image courtesy Jason Benjamin via Flickr.

This article was written by Jonathan John

Jonathan John is a freelance blogger for hire and a WordPress enthusiast.

Hand-picked related articles

  1. Gravatar for this comment's author
    SteeveCo April 12, 2014 at 8:00 pm

    “In short, few really understand how Bitcoin works” this is the best & most truthful thing I’ve read in ages!

    Whenever I’m asked what Bitcoin is I have to say I understand what it is, but can explain how it works. Which gets me strange looks,

    Great post, very informative! Thanks.

    1. Gravatar for this comment's author
      Jonathan John April 13, 2014 at 2:05 am

      Glad you liked it! Thanks for dropping by :).

  2. Gravatar for this comment's author
    Mark Gavalda April 14, 2014 at 3:13 pm

    I think Bitcoin is a great idea and even if it won’t be the ultimate crypto currency that will conquer the world, just like Napster isn’t the P2P file sharing program everyone’s using today, but it has definitely started a revolution that was long overdue, just like Bitcoin did for digital currencies. We’ll be implementing Bitcoin based payments on Kinsta as well, as soon as we get out of the private beta phase! :)

  3. Gravatar for this comment's author
    Peeter Joot May 21, 2014 at 6:59 pm

    There’s a small typo above. Your code introduces a shortcode [bitcointbutton], not [bitcoinbutton] as stated.

    1. Gravatar for this comment's author
      Tom Zs May 22, 2014 at 10:10 am

      Peeter thanks for letting us know already fixed the typo!

  4. Gravatar for this comment's author
    Maryam Shannon December 24, 2014 at 10:32 am

    I just did everything you said and I got an ‘add total’ over and over and no place to add a total O.o. Did I miss something? I followed the instructions exactly.

  5. Gravatar for this comment's author
    Maryam Shannon December 24, 2014 at 10:32 am

    I just did everything you said and I got an ‘add total’ over and over and no place to add a total O.o. Did I miss something? I followed the instructions exactly.

  6. Gravatar for this comment's author
    Joe Strandell April 7, 2015 at 9:30 pm

    Help! I tried doing this and now I can’t access my website. It says “Parse error: syntax error, unexpected ‘bitpay’ (T_STRING), expecting ‘]’ in /home/josephstrandell/public_html/wp-content/themes/balance/functions.php on line 113”

    1. Gravatar for this comment's author
      Mark Gavalda April 7, 2015 at 9:33 pm

      Joe, there’s a syntax error somewhere in that file, if you’re not familiar with PHP coding it might be better to just remove it and ask someone to help you out.

  7. Gravatar for this comment's author
    Har Sears January 12, 2016 at 7:07 am

    I tried creating an account with bitpay but it has locked me out and though it accepts that I have initiated the account with my email address, it won’t recognise it in allowing me to reset. It states “Error sending forgot password request”. Any assistance with this would be greatly appreciated!

    1. Gravatar for this comment's author
      tomzur January 12, 2016 at 10:32 am

      You should contact with Bitpay. They have a help desk.

  8. Gravatar for this comment's author February 14, 2017 at 1:39 pm

    BitPay absolutely positively will NOT allow you to accept donations on your website unless you clear a regulatory hurdle to classify your operation as a Non-Profit. The contents of this article are now quite wrong. Hope this helps.

  9. Gravatar for this comment's author
    Anto May 23, 2017 at 3:36 am

    please donate some money for child dream. thanx!

  10. Gravatar for this comment's author
    Drey Tanoor August 16, 2017 at 6:48 pm

    I can host a bitcoin donation fundraiser qr code on a website that will automatically open wallet Click my name…

  11. Gravatar for this comment's author
    Visualmodo WordPress Themes November 11, 2017 at 3:24 am

    Very good guide!

Leave a Reply

Use WordPress?

Join 20,000+ others who get our FREE weekly newsletter with WordPress tips on how to drive more traffic and revenue to your business!

You have Successfully Subscribed!

Send this to a friend