How do I add a custom Name Badge?
It's not very strait forward, but here are the steps needs, (credit to Kasia Wakarecy) as commented in the old CiviCRM forum (https://forum.civicrm.org/index.php?topic=35420.0):

The new badge templates can be added through Administer > System Settings > Option Groups > Name Badge Format. That interface only allows to enter the new badge name and a description but no info about the layout. To actually tell CiviCRM some details about that badge layout, direct database update is required to add that value:


To know which value to update in the database, run first this query:
SELECT id FROMcivicrm_option_valueWHERE name = "Avery 5392"
where "Avery 5392" is the name of the new badge layout you just added. The result is going to be like id = 847.
Enter the layout details for that badge into the DB using this query:
UPDATE civicrm_option_value
SET value = '{"name":"Avery 5392","paper-size":"letter","metric":"mm","lMargin":2,"tMargin":25.4,"NX":2,"NY":3,"SpaceX":0,"SpaceY":0,"width":101.6,"height":76.2,"font-size":12,"orientation":"portrait","font-name":"helvetica","font-style":"","lPadding":3,"tPadding":3}' WHERE `civicrm_option_value`.`id` = 847;



Update the id = 847 with the id number from the first query.

The fields above mean:

'name' =&gt; '5395' // name of label
'paper-size' =&gt; 'a4' // paper size
'metric' =&gt; 'mm' // units
'lMargin' =&gt; 15 // left margin in mm (because metric = mm)
'tMargin' =&gt; 26 // top margin in mm (because metric = mm)
'NX' =&gt; 2 // number of items in x (left to right) direction
'NY' =&gt; 4 // number of items in y (top to bottom) direction
'SpaceX' =&gt; 10 // spacing between items in x (left to right) direction in mm (because metric = mm)
'SpaceY' =&gt; 5 // spacing between items in y (top to bottom) direction in mm (because metric = mm)
'width' =&gt; 83 // width of one item in mm (because metric = mm)
'height' =&gt; 57 // height of one item in mm (because metric = mm)
'font-size' =&gt; 12 // font size
'lPadding' =&gt; 3 // left padding in mm (because metric = mm)
'tPadding =&gt; 3 // top padding in mm (because metric = mm)



Now, that new layout/template is available when adding new Event Badge Layouts (civicrm/admin/badgelayout?reset=1&amp;action=browse)