Form storage is cleared after ajax submission I am creating a form with "add more" functionality. Form builder retrieves values according to  form built. keys are generated using uuid service. I also have to save them. So they are saved into form storage.

$form_state-&gt;get('links', $links)
...
$form_state-&gt;get('links')


On the next ajax submission storage is empty?!
Also I use a block configuration form. So it uses sub-forms. May be the problem is related with. This is related problem. How to prevent SubFormState storage leaking into parent?
You say this is about building the form. If you display a form on a page, then this form is rendered, but the form object is not stored yet. This happens later when the form is submitted, then you can use $form_state.

Generally when you build a form this is the same like rendering of non form content. Put the initial values in HTML (in the form elements). Similar to default values for visible fields use hidden fields for other values. You also have to add the correct cache metadata to the form so that the render cache varies by the data and is invalidated when the data is modified.

If you don't want to transport data in a rendered form then use a session or tempstore. This kind of storage is not restricted to form requests, so strictly not connected to this issue, but for logged in users these are easily available and for anonymous you can start a session, which you need to do anyway if you want to personalize a form.