Google reCAPTCHA: Basic example to integrate Google reCAPTCHA in Play Application with the help of play-recaptcha module

Playing with Google reCAPTCHA

Basic example to integrate Google reCAPTCHA in Play Application with the help of play-recaptcha module

Play reCAPTCHA Module

This is a Play Framework module, for Scala and Play 2.x, to provide integration with Google reCAPTCHA (version 1 or 2) in a reactive (non-blocking) manner.

google-recaptcha-example-v1 google-recaptcha-example-v2

  • Used Play reCAPTCHA module to integrate Google reCAPTCHA API
  • Embedded JS & CSS libraries with WebJars.
  • Integrating with a CSS framework (Twitter Bootstrap)
  • Bootswatch-Darkly with Twitter Bootstrap to improve the look and feel of the application

Registration Form Screen


Result Screen



The play-recaptcha module is distributed using Maven Central so it can be easily added as a library dependency in your Play Application’s SBT build scripts, as follows:

"com.nappin" %% "play-recaptcha" % "1.0"


The play-recaptcha module supports the following basic configuration settings in your application.conf file:

recaptcha.privateKey=<YOUR Google reCAPTCHA privateKey>
recaptcha.publicKey=<YOUR Google reCAPTCHA publicKey>
#recpatcha.requestTimeout=10 seconds

for more info check here

Build Instructions

  • To run the Play Framework, you need JDK 6 or later
  • Install Typesafe Activator if you do not have it already. You can get it from here
  • Execute ./activator clean compile to build the product
  • Execute ./activator run to execute the product
  • playing-google-recaptcha should now be accessible at localhost:9000


About Anand Kumar Singh

Hi, I’m Anand Singh and I specialize in Computer Software. I’m passionate about what I do, and I love to help people. Nothing is more fulfilling than being part of a team with similar interests, and an organization that values its employees. I'm Lead Software Engineer at Sapient. Having 5+ years of experience in Java, Grails/Groovy and Scala language. Anand also knows about Javascript, jQuery, CSS and other UI design technologies. Certified developer in: * Principles of Reactive Programming – Coursera * Functional Programming Principles in Scala – Coursera * Functional Program Design in Scala – Coursera * Introduction to Big Data with Apache Spark – edX * Oracle Certified Associate (OCA) * Sun Certified Java Programmer (SCJP) I'm passionate to work with upcoming technologies and bleeding platforms providing the new way to programming & development. He is actively involved in development & maintenance of several software projects. He has been enjoying Scala for more than a year now. Anand completed his MCA from IGNOU. As a Developer, I'm continuing my journey by actively collaborating with other Developers in my field. I'm actively contributing on the TechMonad & Playing Scala platform. I likes to spend his free time in Cooking, watching Discovery for new Technology and visiting new places with friends.
This entry was posted in Bootstrap, Bootswatch, Google reCAPTCHA, JavaScript, Play Framework, Play reCAPTCHA, Scala, Web and tagged , , , , , , , , , , , , . Bookmark the permalink.

4 Responses to Google reCAPTCHA: Basic example to integrate Google reCAPTCHA in Play Application with the help of play-recaptcha module

  1. Reblogged this on Play!ng with Scala and commented:

    Google reCAPTCHA

  2. sandeepknol says:

    Reblogged this on sandeepknol.

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s