Articles on: Interactive modules
This article is also available in:

Code based voting: creating, hashing and uploading codes

Code based voting is a specific project feature of your Bpart platform, designed for a voting round. During this voting round, participants can no longer submit contributions or post reactions. They can only vote.


To vote on a code based voting project, participants sign in with a unique code. This code can be a national register number or an identity card number, but also a random code printed on a letter sent to residents.


Once a participant has signed in with a unique code, the regular voting options are available:


  • Participants can vote once on each contribution.
  • As a manager, you set a maximum number of votes per topic or theme. For example: vote for your favourite project (max. 1 vote), or vote for every idea you like (no limit).


This article explains how to correctly create, secure and upload the different types of codes.




When should you use code based voting?

When it is crucial that only a specific group of people (e.g. residents of a neighbourhood, municipality or city) can vote. Think of projects that allocate public money, such as participatory budgeting.

When should you not use code based voting?

For more low-threshold votes, or when citizens should still be able to post new contributions or reactions. Think of voting on new locations for benches or a new name for the youth centre.


Uploading codes securely to Bpart


You don't upload your unique codes directly to Bpart. We handle this securely: each code is first converted into a hash using the SHA3-512 hashing algorithm. Bpart therefore does not store the codes, such as national register numbers, in readable form. When someone votes, the code they enter is hashed in the same way and compared with the uploaded hashes.


Preparation takes four steps:


  1. Compile a list of correct, numeric codes
  2. Add test codes
  3. Hash the codes
  4. Upload the hashes to Bpart


Useful tools for code based voting


Name

Description

Link

Code generator

Create new, random numeric codes

click here

Number extractor

Create clean, numeric codes from an existing list

click here

Code hasher

Hash numeric codes with SHA3-512

click here


Step 1: which codes can I use, and how do I make them numeric?


Bpart code based voting only works with numeric codes. Below you can read how to create such codes yourself, or how to convert an existing list into numeric codes.


Option 1: you create numeric codes yourself


Creating your own codes? Great. Use digits only: no letters, spaces or special characters. You can generate random numbers in Excel or use the Bpart code generator.


Option 2: you use existing codes


Already have a list of codes, such as national register numbers? Perfect. To make sure citizens can vote without any issues, Bpart uses the numeric version of these codes. This avoids formatting problems, such as dots and hyphens used as separators. So you remove all non-numeric characters before hashing and uploading the codes.


Use the Bpart number extractor for this. Copy and paste the codes into the field (e.g. 12.34.56-789.01) and generate the numeric values (e.g. 12345678901).


What does this mean for a citizen or participant?
Participants can enter their code in different ways when voting: with or without spaces, dots, hyphens… That's no problem. The Bpart platform first removes all non-numeric characters and then checks the code via the hash.


Step 2: add test codes


Add a few test codes to your list, so you can test the setup and the vote without using real codes. Ideally, use the same format as the real codes. For national register numbers (11 digits), you could add 12345678901 or 11111111111, for example.


Important: test codes are fully valid voting codes. Undo the test votes you cast with them before the voting round goes live.


Step 3: how do I hash the numeric codes?


We don't upload the numeric codes directly to Bpart. We first secure them with the SHA3-512 hashing algorithm. Use the Bpart code hasher for this. The code hasher runs entirely in your browser: your codes never leave your computer.


  1. Copy and paste the numeric codes into the field (one code per line).
  2. Click Hash now.
  3. Copy the hashes that appear and paste them into a new Excel file. Place one hash per row in the first column.
  4. Save the document as an XLSX file.


You now have a list of secure hashes.


Step 4: how do I upload the hashes to Bpart?


Go to the Voting section of your project and upload the XLSX file with hashes under Voters. You can also add one specific hash or code using the New button.


Points of attention


  • Watch out for leading zeros. A national register number starts with the date of birth (YYMMDD). For people born in 2000–2009, the number therefore starts with at least one zero, and for those born between January and September 2000, even with three zeros. Excel often hides or removes these zeros. So set the column to Text before pasting the codes, and check the result carefully. A missing zero produces a different hash, and that person will not be able to vote.
  • Make sure you have a clean list of numeric codes. Anything else you hash along with the codes (spaces, special characters, letters, empty lines…) will cause problems when voting.
  • Add test codes in the same format as the real codes, and remove them (together with the test votes) before the voting round starts.
  • Configure your voting settings correctly, e.g. a maximum of 1 vote per topic.


itsme and eid in Flanders


Government in Flanders? Discover how you can use our itsme (mijn burgerprofiel) integration.

Updated on: 22/10/2026

Was this article helpful?

Share your feedback

Cancel

Thank you!