Customized Code – Rate My App Code

To help you on your way with customization, Appsgeyser will be providing some basic codes that you can simply copy and paste into the script section that is situated within the ‘Advanced Edit’  tab.

Today’s code will help you create a pop up box called ‘rate my app’.

This code will create a pop-up window that asks the user to rate your app on Google Play. By tapping ‘Yes’, the user will be redirected to your App’s page on Google Play. This pop-up will not appear numerous times, but will be shown only once after a certain amount of time spent in the app. Please note that this code will only work for apps that are published on GooglePlay. To view the code, click on the image below.


var packageName=encodeURIComponent(AppsgeyserJSInterface.getAppPackageName());
setTimeout(function(){
rateItShow = AppsgeyserJSInterface.getItem('rateIt')=='true';
if(AppsgeyserJSInterface.getItem('rateIt')==null){
if (window.confirm("Please, rate this app") == true) { /* Enter pop-up text */
AppsgeyserJSInterface.setItem('rateIt',rateItShow ?'true':'false');
window.location='market://details?id='+packageName;
} else {
AppsgeyserJSInterface.setItem('rateIt',rateItShow ?'true':'false');
}
}
}, 60000); /* Message will pop-up once after 60 seconds spent in app.
Enter your time value in milliseconds, eg: 60000 ms = 60 sec, 30000 ms = 30 sec, 1000 ms = 1 sec */

edit your android app

Then click on Advanced Edit.

choose edit app
Choose Edit app to edit your free android app.

Scroll to the bottom and add in your customized code.

add embed code

This is what the app will look like before and after:

advance app preview
Before the code has been added. No pop up.
rate my app pop up
After the code has been added. With pop up.

We wish you the best of luck with your app and hope that you enjoy adding in customized code to your app.

Appsgeyser will be adding more codes over the coming few weeks. Don’t forget to come back and learn some more.

*codes are not available on every template. Please check the advanced edit section to see if the coding area is open

Last Updated on December 15th, 2023