Developing a cross platform RAM meter using Neutralinojs

NeutralinoJs is a lightweight portable framework for developing web apps with native os functions. Today we have reached 160 stars on Github from the open source community. Take a look and give us a star if you are interested 😀.

Motivation 💪

Today we are going to build a “RAM meter” which shows the used portion of RAM as a percentage.

RAM Meter UI

Downloading Resources

Download a fresh copy of Neutralino SDK latest version (< 1MB with Windows and Linux support)

Download CSS percentage circle CSS script which provides colorful percentage circles.

Try executing the neutralino binary and check whether you are getting the default Neutralino app template. 👀

Developing the app

Design awesome UI

Simply link the circle.css and add some ids to identify elements via Javascript.


<!DOCTYPE html>
<meta charset="UTF-8">
<link rel="stylesheet" href="/assets/app.css">
<link rel="stylesheet" href="/assets/circle.css">
<div id="neutralinoapp">
<div id="meter" class="c100 p0 big">
<span id="percentage">0%</span>
<div class="slice">
<div class="bar"></div>
<div class="fill"></div>
<script src="/neutralino.js"></script>
<script src="/assets/app.js"></script>

Writing the application

Write the application logic using Javascript. Here we can simply use to fetch current RAM status 😎.


let myapp = {
myfunction : () => {
setInterval(() => { => {
let percentage = parseInt((( - data.ram.available) / * 100);
document.getElementById('percentage').innerHTML = `${percentage} %`;
document.getElementById('meter').className = `c100 p${percentage} big`

}, () => {});

load: () => {
pingSuccessCallback : () => {

pingFailCallback : () => {

data contains the RAM’s total size and available size in bytes.

JSON response


Since the UI needs to be updated frequently we can put these things inside a setInerval() block.

Give a try to improve this simple RAM meter. Send us a PR if you have improved version 😋

Note : if you are running on Linux please use data instead of data.ram

Source code :

Happy coding!!