Okay, so I wanted to make a simple countdown timer for, you know, Honkai: Star Rail’s upcoming stuff. I’m not a coder, but I figured, how hard could it be, right?
First, I needed to figure out what I wanted to count down to. I grabbed the date of the next patch, or a character banner, whatever – let’s just say, for this example, it’s May 28th, 2024. I literally just Googled it.

The Setup
I decided to keep it super simple, just HTML and JavaScript, no fancy libraries or anything. I opened up a basic text editor and knocked out some HTML:
- Added some basic tags.
- Created a <div> to put the timer on page
- And created a <p> tag inside of the div to show the timer, and give it a id.
The JavaScript Part
Next up, the JavaScript. This is where the actual counting happens. I started with the date in the future. It can be done by creating a new Date Object in JavaScript.
Then, I created a function that did a few things:
- Got the current date and time.
- Calculated the difference between the future date and the current date.
- Worked out the days, hours, minutes, and seconds from that difference.
Then the function updated the innerHTML for countdown.
And set an interval that runs one second.
Making It Look Okay
Then added some very basic CSS to make it not look horrible. Centered the text, gave it a bit of a font size, that kind of thing. Nothing fancy, I just wanted it to be readable.

Putting It All Together
Finally, I put the JavaScript code into a <script></script> tag at the bottom of my HTML file, saved it, and opened it in my browser. And… it worked! I had a little countdown timer ticking away. It wasn’t pretty, but it did the job. Felt pretty good for a non-coder, to be honest.