I've decided to use Argon2id for storing users' passwords in my database. I have two questions:

  1. Because there are several input parameters (parallelism, iterations etc.) that can influence the output result so I'm wondering if it's a good idea to store those parameters in the database e.g. in a column next to the stored passwords. Can it decrease somehow the security?
  2. Because the users who use our application can have a different computer (our application is running on their side, it's a windows app) thus also a different computing power. How to correct set those parameters so it is secure enough but not too slow for users? Is there any recommended settings? Or the best way would be to run a performance test before a first run of the app and choose the parameters according to that (e.g. a goal is that the calculation of the hash password has to bee between 300-500 ms)
  • 1
    Hi and welcome to the site! Is this a web service? In that case the hash should be computed on the server, so the users computing power is irrelevant.
    – Anders
    Jan 7, 2020 at 9:58
  • The API already help you to store in on column Which part of this encoded Argon2 hash is the salt?. We should design the system even the database is compromised. The time,memory and computing power all can be measurable. According to your risk selet parameters...
    – kelalaka
    Jan 7, 2020 at 10:01
  • No, it is a Windows app because I'm wondering about parameters. Mainly, it's running on a Windows server edition. @kelalaka Thanks, I'm going to read it. Jan 7, 2020 at 10:04
  • Not sure I understand what "their side" means. Password hashing should take place server side, not client side. That is the important point here.
    – Anders
    Jan 7, 2020 at 10:14
  • Yes, the passpord hashing takes place on the server side but on the customer hardware and then their users connect to this server. So every customer can have a different hardware on the server. I'm not sure if it's a bit clearer now. Jan 8, 2020 at 7:50

1 Answer 1


Question 1

You need to store all the information, but you should store it encoded in a single column. You probably already get the encoded output from your hash library. It should look something like this (source):


To understand what the different part means, see this question.

Question 2

Note that password hashing should take place server side, so it is not the client machines you should care about. But I assume this is some sort of server software that might run on servers with different performance.

If would advice you to make this configurable, and set a strong secure default even if it might be to slow for some machines. You should probably update these defaults in future versions as well, as best practice evolves and hardware improves. (I don't know what that would mean for Argon2 in the year of 2020.)

To help people who run into performance issues, I would aim to write good documentaiton explaining why they have this issue and why using lower settings would be risky.

Setting a weak default or just doing a performance test would come with the risk of people unknowingly using unsafe settings. I would rather force my users to think about this issue than give them a false sense of security.


You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .