DEV Community

Dídac
Dídac

Posted on

Mining cryptocurrencies instead of having ads?

Today I saw a tweet from @ben that had a dev.to link talking about ads that made me remember something that I saw some weeks ago:

Liquid error: internal

Coinhive

Coinhive offers a Javascript API for mining a cryptocurrency called Monero in your own website so instead of having a tons of ads you ask for some processing power for mining to the user.

Concepts (I got this from their website):

  • Captcha: We offer an easy to implement captcha-like service where users need to solve a number of hashes (adjustable by you) in order to submit a form. This prevents spam at an inconvenience that is comparable to a classic captcha. All with the added benefit of earning you money.

  • Shortlinks: If you have an URL you'd like to forward your users to, you can create a cnhv.co shortlink to it. The user has to solves a number of hashes (adjustable by you) and is automatically forwarded to the target URL afterwards.

  • Javascript API: If you don't like the captcha or shortlinks for whatever reason, nothing is stopping you from implementing your own solution on top of our API.
    The JavaScript API let's you associate solved hashes to specific users on your site. Users can solve hashes on your behalf in return for benefits you provide.


I think this super interesting in captcha and short links but I would not like it that much if all my tabs are mining at the same time.

Do you think that this will become the new ads?

Do you know some potential problems that we could encounter as users?

Please share your opinion.

Top comments (14)

Collapse
 
ben profile image
Ben Halpern

Interesting... I'm going to give this a lot of thought. This is so off the wall, I'm not quite sure how I feel. I'll let it sink in, and would love to read more opinions.

Collapse
 
valtism profile image
Dan Wood

As far as I know, it is very difficult to make any money at all with crypto mining, as the computing power required to mine a significant amount is far too high.

I don't like mining crypto as an alternative to ads in the first place because of the impact that they have on battery life of my devices. Losing an hour of battery from visiting a site seems like a higher price to pay then viewing even an annoying ad.

Collapse
 
jess profile image
Jess Lee

@peter I’m specifically interested in your opinion on this

Collapse
 
mortoray profile image
edA‑qa mort‑ora‑y

Sites, and networks, that abuse the end-user's computer should, and will, rightfully by labelled as malware. They will be aggressively blocked, and hopefully filtered out by search engines.

This is a shady practice that disrepects the user's equipment, costs the user money, and is bad for the environment.

It's like a mall that robs of you your wallet when you enter for fear that you might not enter any of the stores.

Collapse
 
jpenuchot profile image
Jules Pénuchot

Mining currencies using JS scripts is incredibly inefficient (not just because JS is slow but also because it can only run on CPU, and CPUs are incredibly slow at solving hashes) and crypto-mining is already a huge waste of energy. It would just drain our devices' batteries, increase overall energy consumption, without even generating decent revenues for website holders.

Collapse
 
bushwald profile image
Brad • Edited

I'd prefer easy micro-payments in the form of mining that don't require any financial info from me over brainwashing via ads. I'm curious if there are any API's in development that would do the mining on the gpu, rather than cpu, like WebGL. Wouldn't that solve some of the concerns about efficiency?

Collapse
 
tachyon profile image
Flavius • Edited

I've created an implementation of crypto mining into my game, it's a pretty nifty feature and the community seems to enjoy it. I've done some research, and it won't be flagged or ad-blocked unless you do not disclose this to the users.

thepracticaldev.s3.amazonaws.com/i...

Collapse
 
shell profile image
Vladimir Penkin

As multiple commenters pointed crypto-mining on user's computers have multiple problems but it doesn't mean that it can't be solved people! We in the beginning of something new and nobody knows all the right answers yet.
But if I have to choose I would choose mining instead of ADs.
Maybe because they haven't worked for me in particular and I find them stupid.
And as we found with journalism, there are 2 parts of the equasion.

  1. Journalists want to be paid fairly for professionalism
  2. People mostly not ready to spend bucks for each site they read, specially that is there are plenty of other sources. Hence we have ADs. But they are not ideal as well. Something we saw on the example of youtube and ADpocalypse, or native advertisements or any other number of problems using ADs.

So my vote is YES, I'm ready to share resources of my computer(electricity, idle time, disk space, whatever, network bandwidth) to "pay" for quality content.

Collapse
 
therufa profile image
Attila Max Ruf

i think crypto mining is good, because it creates a market for revoltionizing the way we produce electricity. if there's a problem it needs to be solved, not avoided.

i would be happy to support the pages i visit using crypto mining, especially those media that hide content unless ad blockers are disabled

Collapse
 
rhymes profile image
rhymes

I'm thinking about this:

"Bitcoin Mining Now Consuming More Electricity Than 159 Countries Including Ireland & Most Countries In Africa"

powercompare.co.uk/bitcoin/

so my answer would be "sorry but no" :-)