Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

iTechGuides is reader-supported. When you buy through links on our site, we may earn an affiliate commission. As an Amazon Associate I earn from qualifying purchases. Learn more

A short script can make the winner selection replayable—but only after you commit to a secret seed, freeze the entrant list and rules, and publish enough information for entrants to repeat the calculation. The example below uses Node.js 26.8.1 and HMAC-SHA256 to demonstrate deterministic selection; it is not a complete giveaway system or a guarantee that the organizer handled entries honestly.

What a replayable draw can—and cannot—prove

A commit-reveal draw lets an organizer publish a hash of a secret server seed before the remaining draw inputs are fixed. After the draw, the organizer reveals the seed. Entrants can hash it to check it matches the earlier commitment, then use the disclosed inputs and algorithm to reproduce the selected winner. This is the core approach described in Provable.IO’s provable-core repository.

That proves only a narrow claim: the revealed seed matches the prior commitment, and the result follows from the published inputs and procedure. It does not establish that the entrant list was complete, that eligibility rules were applied impartially, or that the organizer will award the prize. Those parts require transparent rules, a verifiable entry record, and responsible administration.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Publish the draw rules and inputs before the cutoff

Before accepting the final draw inputs, post the commitment hash somewhere participants can access. Also publish the information needed to define the draw:

#1 Best Overall
Visa Physical Gift Card $100 (plus $5.95 Purchase Fee)
  • Gift Cards are shipped active and ready for use.
  • This card is non-reloadable. No cash or ATM access. Funds do not expire. If available funds remain on your card after the valid thru date has passed, please call customer service for a replacement card. A one-time purchase fee applies at the time of checkout. No fees after purchase.
  • To access your card information safely, type the complete website address shown on your Gift Card (MyGift.GiftCardMall.com) directly into your browser's address bar. Don't use search engines or shortened versions of the website address, as these may lead you to fake or fraudulent sites. Do not provide any Gift Card details (example: Card Number) to someone you do not know or trust. If you believe you've reached an illegitimate website, contact cardholder service at 1-888-524-1283. Be cautious of phishing sites, there are a variety of scams in which fraudsters try to trick others into paying with gift cards.
  • To report your Lost or Stolen Physical Visa Card, call Customer Service 24/7 at 1 (888) 524-1283 to cancel your Gift Card as soon as you can. You will be asked to provide the Gift Card number and other identifying information.
  • Use your Visa Gift Card in the U.S. everywhere Visa debit cards are accepted, including online.
  • Entry cutoff, eligibility rules, duplicate and invalid-entry handling, and the number of winners.
  • The entrant list in a fixed order. If you publish only a digest, provide an accessible way for participants to verify the exact list represented by it.
  • The exact selection algorithm, including how it maps output to an entrant index.
  • The commitment hash and, after selection, the revealed seed and result record.

Freeze the entrant list and rules before deriving the winner. A seed commitment cannot verify information that was never published or included in the agreed procedure.

Ten-line Node.js example

This illustrative snippet assumes you already have a fixed, ordered entrants array, a secret serverSeed, and a public clientSeed. It uses a SHA-256 HMAC digest as a deterministic number source, then rejects values outside the largest range divisible by the entrant count. Rejection avoids the modulo bias that would result from simply taking a digest value modulo the list length.

Rank #2
BIMORITA 24Pcs Mini Multicolor Pens in One 4-in-1, Cute Pens Bulk for Party Favors and Birthdays, Delightful Ballpoint Pen Back To School Gifts Classroom Student Prizes
  • Creative Cute Pens: This fun set includes 24 mini ballpoint pens, each with a unique and charming cartoon theme—ranging from animals and fruits to snacks and veggies. These colorful pens are perfect for students who love expressing their creativity and personal style, adding a playful touch to writing, drawing, or note-taking
  • Comfortable and Easy to Use: Made slightly shorter for smaller hands, these pens are ideal for students. The ergonomic design ensures a comfortable grip, while the fun, eye-catching designs make them a joy to use for both schoolwork and playtime
  • Multicolor Pens 4-in-1 Convenience: Each pen features four vibrant ink colors—red, green, gray, and blue—making switching between colors quick and effortless. Great for doodling, journaling, color-coding, or writing, these pens deliver smooth, smudge-free lines every time
  • Wide Application:Easily switch between all four colours with these multi-colour pens. These kawaii pens are practical, ideal choice for birthday, holiday gift, school supplies, classroom prizes, party favor or daliy use, fun gifts for students classmate friends nurse
  • The Perfect Gift:With bright colors and fun themes, these pens make the perfect gift for students on birthdays, Christmas, or other special occasions. Each pen combines playful design with everyday practicality—sure to become a favorite in any student’s collection
const { createHmac, createHash } = require('node:crypto');
const entrants = ['Avery', 'Blake', 'Casey'];
const serverSeed = process.env.SERVER_SEED;
const clientSeed = 'giveaway-2026-01';
const commitment = createHash('sha256').update(serverSeed).digest('hex');
const n = entrants.length;
let counter = 0, x, limit = Math.floor(2 ** 32 / n) * n;
do { x = createHmac('sha256', serverSeed).update(`${clientSeed}:${counter++}`).digest().readUInt32BE(0); } while (x >= limit);
const winner = entrants[x % n];
console.log({ commitment, winner });

The code is a compact demonstration, not a complete production implementation. It assumes at least one entrant, uses the first 32 bits of each HMAC digest block, and increments a counter when rejecting an out-of-range value. An independent verifier must implement the same byte selection, encoding, message format, counter behavior, and entrant ordering. Keep the seed secret until after the draw; do not publish it with the commitment.

Free tools Windows power users keep installed

One-click scans. No signup required.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

How participants verify the result

  1. Check the commitment: after the organizer reveals the server seed, calculate its SHA-256 hash and compare it with the previously published commitment.
  2. Recreate the inputs: obtain the exact ordered entrant list, client seed, cutoff and rule record, winner count, and algorithm version used for the draw.
  3. Recompute the selection: run an independent implementation using those inputs and confirm that it produces the published winner.

If the hash differs, the revealed seed does not match the commitment. If the hash matches but the recomputed winner differs, at least one published input or implementation detail is inconsistent. A matching result still cannot prove that the original entrant list or eligibility decisions were fair.

Rank #3
AZEN 8 Sets Bulk Gifts, Hand Cream and Lip Balm Bulk Set with Organza Bag Thank You Card, Baby Shower Wedding Gifts for Guests, Bridal Wedding Favors for Guests,Thank You Gift for Women
  • Sufficient Coworker Gifts: This set includes 8 hand creams, 8 lip balms, 8 white organza bags and 8 thank-you labels. These are enough to share with family and friends during the wedding, and they are a good combination to meet your gift-giving needs
  • Flavored Gift Sets: These lip balms have 8 flavors - Strawberry, Watermelon, Mango, Coconut,Pineapple, Vanilla, Mint, Grape, Peach, Orange. And these hand creams have 6 flavors - freesia, lily, peach, grapefruit, apple mango, green tea
  • Moisturizing & Soothing: Our lip balm and hand cream is rich in powerful skin care ingredients, which has moisturizing and soothing effects. At the same time, they come with different and refreshing scents, let you have a happy mood, and provide you with a good experience
  • Versatile Use: Thank you themed hand cream gift is suitable for various occasions; You can use it at home with your family, or take it to school, office, etc. It is also a nice gift for girlfriend, wife, mother, colleagues, teachers, and even yourself on birthday, anniversary, etc. It is also a beautiful gift set for church activities and gatherings
  • DIY Your Own Gift: You can write down what you want to say to your guests on the card tags, or you can put the lip balm and hand cream in the organza gift bag, just diy your own shower favors gifts for the guests

Why ordinary random integers are not replayable

Node.js crypto.randomInt(min, max) returns an integer from the inclusive lower bound to the exclusive upper bound and avoids modulo bias. The Node.js 26.8.1 documentation states that the range must be less than 248 and both bounds must be safe integers: Node.js Crypto documentation v26.8.1. It is suitable for ordinary random selection, but it is not seeded for public replay. A reproducible commit-reveal draw needs a deterministic derivation and an explicitly specified unbiased mapping, as in the example’s rejection step.

Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Support on Ko-Fi

Hosted commit-reveal services are one implementation option

A hosted API may manage commitment and reveal operations, but its workflow is service-specific rather than a universal requirement. For example, Provable.IO’s API reference documents a commit endpoint that returns a commitment ID and server hash, followed by a single-use reveal request with a client seed and generation parameters. Its reference lists a default commitment time-to-live of 10 minutes; confirm current service documentation before relying on that limit. The Getting started guide describes a guided implementation and replay instructions.

Rank #4
Purpeak 24 Set Retractable Back Scratchers Thank You Cards Party Prizes
  • Employee Appreciation Gifts Bulk: the back scratcher gifts bulk includes a comprehensive package: 24 retractable back scratchers, 24 inspiration bookmark cards, 24 metal twist ties, and 24 OPP bags; This ample supply allows you to customize and gift these thoughtful items to friends and family, making each present unique and meaningful
  • Pull It to the Exact Length You Want: our telescoping back scratchers offer a flexible size range from approximately 7.9 inches to 26 inches; This adjustable design allows users to easily lock their desired length, providing a convenient and relaxing experience anytime and anywhere, making it an ideal choice for adults
  • Quality Material: each back scratcher is crafted from durable stainless steel, ensuring resistance to rust and longevity; The robust construction maintains stability even when fully extended, and the comfortable PP rubber handle suits both men and women, enhancing the user experience
  • Be Proud of You: “Thank you—may you be proud of the work you do, the person you are, and the difference you make; ” A thoughtful way to express appreciation for employees, colleagues, and team members; It honors their dedication, character, and meaningful contributions, combining warmth and professionalism to make every recipient feel seen, valued, and inspired
  • Thoughtful Gift for Various Occasions: This back scratcher christian gifts bulk serves as a considerate present for friends, family, colleagues, or employees. Lightweight and portable, it provides a comfortable relaxation experience, making it an excellent choice for Christmas gifts, birthday party favors, end of year gift bag fillers, or decorations

Whether you host the process yourself or use a service, publish the inputs and receipt needed for independent verification. A service can simplify integration; it does not, by itself, establish that your entrant list or eligibility decisions were honest.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
Best Value
Eersida 200 Pcs Scratch Off Cards with Round Stickers,Thank You Style
  • Scratch off Cards and Stickers Set: you will get 200 scratch off cards for small business with a size of about 1.97 x 3.54 inches/ 5 x 9 cm, and a roll of 300 round scratch off labels 1 inch/ 2.5 cm; Ideal for small business activities and occasions, anniversary scratch card and gift ideas; Write your own gift to customize the gift for any event or occasion
  • Easy to Use: you just need to write any text in the blank circle on the scratch card, which can be prizes and customized gifts, game ideas, blessings, thank you letters to customers or guests and more; After writing, tear off the silver gray scratch off stickers and then cover the text; The back of this card is blank to allowing you to write a personal note or thank you to your customer or guest
  • Quality Material: blank gift certificate scratch cards are made of thick card stock, and each card is easy to write with any type of pen; And it uses holographic design, gorgeous and fashionable
  • Gift Certificates for Business: each card is blank, you can print words or sayings that imply good wishes, expectations for the recipient, or write any prizes of your choice on the blank space to offer your customers or guests; Your customers or guests will love these fun gift certificate scratch cards, which will help your small business leave a good impression
  • Occasion to Use: there is no text on the card, you can set any content and rules by yourself, which offers endless creative possibilities; These blank scratch cards are applicable to small business events, family gatherings, restaurants, hair salons, birthday parties, or other holiday gatherings, keeping your guests entertained and delighted through games and interactive sessions

Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.