In 3AMK libraries, we are using special printers for printing spine labels. Our printer models are Datamax E-4203, Datamax E-4204, Attune Delta A2 and TSC TA310.
The label sizes are 38mm x 25mm (Haaga-Helia, Laurea) and 36mm x 23mm (Metropolia)
We are printing labels using browsers Firefox ESR and/or Google Chrome. Notice! Documentation has slightly old screenshots from an older Firefox version. I'll update this soon! (24.1.2024 Johanna).

Here's our documentation (pdf) about printing in Koha using Label Maker plugin (document is in Finnish "Selkätarratulostus Kohassa Datamax- ja Attune-kirjoittimille") >


Steps to consider when printing labels, e.g. spine labels


1. Need for different layouts

Label 1. All information is taken from itemcallnumber


The label should look like this.

On the first line there is shelf number
On the second line main word (VEAL) is printed.
- The challenge: If the main word is long, it is splitted to the third/fourth line.


Label 2. All information is taken from itemcallnumber


The label should look like this.

On the first line there is shelf number. BTW, the longest shelf number is 658.8.012.1 (at Pasila campus).
One the second line, main word (PILLOT DE CHENECEY) is cropped to 3 characters (PIL).

2. How to get labels libraries need?

Option 1. Koha's Tools > Catalog: Quick spine label creator

  • Suitable for libraries which use only one-type of label

Option 2. Koha's Tools > Catalog: Label creator

https://koha-kktest.lib.helsinki.fi/cgi-bin/koha/labels/label-home.pl

To test this, one can create a template and a label layout (e.g. name both as Finn-ID 38mm x 25mm), and printer profile (Datamax/Attune) on Koha test server.

  • I managed to print labels for Haaga campus. So this method works in some libraries!
  • If you need labels where call number is splitted to the second line and to 3-letters/characters, use option 4.

Option 3. Koha-Suomi's Visual Label tool plugin

Plugin has been developed during spring 2022 by Koha-Suomi to work with Koha's Community version.
Documentation and download from https://github.com/KohaSuomi/koha-plugin-visual-label-tool

  • Haven't tested this yet in 3AMK (25.1.2024 Johanna)

Option 4. Label Maker plugin by ByWater Solutions

  1. Label Creator plugin blog and video instructions: 
    1. Part 1:  https://bywatersolutions.com/education/label-creator-plugin  
    2. Part 1, video:  Label Maker Koha Plugin Part 1
    3. Part 2: https://bywatersolutions.com/education/using-the-label-plugin-in-koha-part-2
    4. Part 2, video: Label Maker Plugin Koha Part 2
  2. Github: https://github.com/bywatersolutions/koha-plugin-label-maker  
    1. KPZ-file: https://github.com/bywatersolutions/koha-plugin-label-maker/releases    

The plugin is installed in Koha test server, and can be used:
https://koha-kktest.lib.helsinki.fi/cgi-bin/koha/plugins/plugins-home.pl

  • In your own Koha, go to Administrator > Manage plugins > Plugins
  • Install latest KPZ-file from Github

    Notice! 0.0.7 and newer plugins creates an extra, empty label.
    E.g. if in your batch there are 2 or more labels, printing creates 3 labels (last one is empty). Not good, so it has to be investigated, why this happens.
    There is no such problem with version 0.0.6 (3AMK). Same template and layouts are used in both versions. Maybe template/layout code needs tweaking?

  • Click button Actions > Run tool
  • Plugin can also be found via Tools > Tool plugins > Label Maker
  • Default templates are: Avery Standard Labels and Basix 55-459-007 (do not delete those)
  • Copy additional templates and layouts from here, or from Koha3 test server, for Datamax and Attune printers (do not delete, copy if you want to create your own templates):

Template for Finn-ID 38mm x 25mm (Itemcallnumber, Pääsana kokonaan)

[% FOREACH item IN items %]
    [% IF loop.index % 1 == 0 %]
        [% SET label_index = 1 %]
        [% UNLESS loop.first %]
            </span>
        [% END %]
        <span class="page">
    [% END %]

    <div class="label label[% label_index %]">
        [% item.itemcallnumber.replace('^(\S+)\s+(\S+).*', '$1<br>$2') %]
</div> [% IF loop.last %]</span>[% END %] [% SET label_index = label_index + 1 %] [% END %]

Template for Finn-ID 38mm x 25mm (itemcallnumber, Pääsana 3-kirjaiminen)

[% FOREACH item IN items %]
    [% IF loop.index % 1 == 0 %]
        [% SET label_index = 1 %]
        [% UNLESS loop.first %]
            </span>
        [% END %]
        <span class="page">
    [% END %]

    <div class="label label[% label_index %]">
        [% item.itemcallnumber.replace('^(\S+)\s+(\S{0,3}).*', '$1<br>$2') %]
    </div>
    [% IF loop.last %]</span>[% END %]
    [% SET label_index = label_index + 1 %]
[% END %]

Layout for Finn-ID 38mm x 25mm (Arial 12)

  • Basic layout that you can easily modify for your own purposes
  • padding-top: 3-6mm (In Haaga-Helia, we use value 3mm here)
  • margin-left; 5-6mm (In Haaga-Helia, we use value 6mm here)
html, body, div, span, h1 {
  margin: 0;
  padding: 1;
  border: 0;
}

body {
  width: 43mm; /* Width of label page */
  height: 30mm; /* Height of label page */
  font-family: Arial;
}

.page {
  padding-top: 6mm; /* Height from top of page to top of first label row */  
  margin-left: 6mm; /* Width of gap from left of page to left edge of first label column */

  page-break-after: always;
  clear: left;
  display: block;
}

.label {
  width: 38mm; /* Width of actual label */
  height: 25mm; /* Height of actual label */
  margin-right: 0in; /* Distance between each column of labels */

  float: left;

  text-align: left;
  font-weight: bold;
  font-size: 12px;
  overflow: hidden;
}

  /* Uncomment for testing and debugging */
  /* outline: 1px dotted; */
}

.page-break  {
  clear: left;
  display: block;
  page-break-after: always;
}

Layout for Finn-ID KAPEAMPI 36mm x 23mm (Arial 12)

html, body, div, span, h1 {
  margin: 0;
  padding: 1;
  border: 0;
}

body {
  width: 38mm; /* Width of label page */
  height: 28mm; /* Height of label page */
  font-family: Arial;
}

.page {
  padding-top: 6mm; /* Height from top of page to top of first label row */  
  margin-left: 5mm; /* Width of gap from left of page to left edge of first label column */

  page-break-after: always;
  clear: left;
  display: block;
}

.label {
  width: 36mm; /* Width of actual label */
  height: 23mm; /* Height of actual label */
  margin-right: 0in; /* Distance between each column of labels */

  float: left;

  text-align: left;
  font-weight: bold;
  font-size: 12px;
  overflow: hidden;
}

  /* Uncomment for testing and debugging */
  /* outline: 1px dotted; */
}

.page-break  {
  clear: left;
  display: block;
  page-break-after: always;
}

Layout for Finn-ID 38mm x 25mm (Arial 16)

html, body, div, span, h1 {
  margin: 0;
  padding: 1;
  border: 0;
}

body {
  width: 43mm; /* Width of label page */
  height: 30mm; /* Height of label page */
  font-family: Arial;
}

.page {
  padding-top: 2mm; /* Height from top of page to top of first label row */  
  margin-left: 8mm; /* Width of gap from left of page to left edge of first label column */

  page-break-after: always;
  clear: left;
  display: block;
}

.label {
  width: 38mm; /* Width of actual label */
  height: 25mm; /* Height of actual label */
  margin-right: 0in; /* Distance between each column of labels */

  float: left;

  text-align: left;
  font-weight: bold;
  font-size: 16px;
  overflow: hidden;
}

  /* Uncomment for testing and debugging */
  /* outline: 1px dotted; */
}

.page-break  {
  clear: left;
  display: block;
  page-break-after: always;
}
  • On KohaTest server (kktest), there are batches with several items, and you can use those to test printing.

Printer profiles

  • There are no examples on how to set Printer profiles. Not needed at 3AMK libraries. / 25.1.2024 Johanna

3. How to print labels using Koha's Label creator and Label Maker plugin (after all printer settings, templates and layouts are set)

  1. Go to Tools - Tool plugins > Label Maker
  2. Click New - Label batch
  3. It will take you Koha's own tool "Label creator". Add barcodes you want to print.
  4. Go back to Label Maker plugin and click Print labels
    1. Select the batch that includes barcodes you want to print to labels (batch number)
    2. Select the template
    3. Select layout
    4. No need to select printer profile (since we don't have one yet, - because we don't know how to create one by coding)
    5. Click Print labels

5. In Browser preview window (Firefox), select Print from right-side menu
6. Print Setup - Format & Options (landscape, scale 130, %, uncross Shrink to fit Page Width)
7. Print Setup Margins & Header/Footer - 0 margins to all, blank to all
8. Then click Print
9. Choose Microsoft Print to PDF, and create pdf. Save pdf to e.g. Desktop, use separate folder that is easy to locate.
10. Print pdf by choosing the label printer like Datamax, Attune, TSC. Check that Page sizing and Handling you have Actual fit; and orientation is here Portrait.

See attached document about settings in Datamax and Attune printers >

4. Managing label batches

  • Label batches can be managed in Koha's own tool (Label creator)
  • Home › Tools › Label creator › Batches
  • Delete unnecessary batches.
  • One easy practice is keep one Batch ID per staff member. But, keep at least one item on the batch. Add new barcodes and delete old ones away.


Helpful links when modifying layouts

Conversion of Measurement Units
CSS Tutorial (for padding, margins etc.)
CSS Web Safe Fonts
Font families


  • No labels