How to create Ripple (XRP) address with JavaScript?

Hideyoshi Moriya
1 min readAug 23, 2018


Install ripple-lib

$ npm install ripple-lib

Example code

  • This example code works in offline.
const RippleAPI = require('ripple-lib').RippleAPI;
const api = new RippleAPI();
const address = api.generateAddress();
console.log('address', address.address);
console.log('secret', address.secret);


If you find this article is helpful, it would be greatly appreciated if you could tip XRP to the address below. Thank you!