Writing music on Tab Lab

While reading music on Tab Lab requires no special knowlege or even an account, writing music may seem a little unfamiliar at first. We've carefully crafted the site to be an equally easy resource for finding and learning songs, as it is for writing them.

Tab Lab uses the VexTab syntax to write staff notation and tablature. Simply put, VexTab is:

...a language that allows you to easily create, edit, and share standard notation and guitar tablature. Unlike ASCII tab, which is designed for readability, VexTab is designed for writeability.

vextab.com

For example

This passage was rendered using only 2 lines of text:

tabstave notation = true clef = treble time = 4/4 key = B notes :8 2/5 2/5 5/5 :16 2/5 2/4t2/4

Below, you'll see a series of terms describing the type of notation to display (both tablature and staff notation), the time signature, and the key. You'll also see a series of notes. Pay close attention to how each note gets translated and rendered in the example above. The syntax used describes each note by it's fret/string number and the note's duration.

tabstave notation = true clef = treble time = 4/4 key = B
notes :8 2/5 2/5 5/5 :16 2/5 2/4t2/4

To help users understand how to use VexTab when writing music, we've put together a reference guide — also accessible right from the song editor, so it's right where you need it.

Handy VexTab Reference Guide

Tab Lab's guide to the VexTab syntax.

Table of Contents

  1. Creating the staff
  2. Adding notes and rests
  3. Note duration
  4. Triplets
  5. Chords
  6. Barlines and repeats
  7. Ties, bends, and vibrato
  8. Hammer-ons, pull-offs, and slides
  9. Annotations, lyrics, and text
  10. Spacing and formatting

Creating the staff

All songs must begin with the tabstave. Use the keyword tabstave to generate it. To activate other features such as notation, different clefs, keys, and time signatures use the following keywords and values:

keyword value
notation true/false
tablature true/false
clef treble, alto, tenor, bass, percussion
key C, Am, F, Dm, Bb, Gm, Eb, Cm, Ab, Fm, Db, Bbm, Gb, Ebm, Cb, Abm, G, Em, D, Bm, A, F#m, E, C#m, B, G#m, F#, D#m, C#, A#m
time C, C|, #/#
tuning standard, dropd, eb, E/5, B/4, G/4, D/4, A/3, E/3
For example:

tabstave notation = true key = Bm

tabstave notation = true key = Bm

Adding notes and rests

Notes can be added using the notes keyword, then specifing a fret number / string number, or a note name / its octave. Rests can be added using the ## syntax.

For example:

tabstave notation = true time = 4/4
notes 3/1 ## E/4 ##

tabstave notation = true time=4/4 notes 3/1 ## E/4 ##

Note duration

To add different durations of notes and rests, e.g., quarters, eighths, sixteenths, use the following modifiers BEFORE the notes or rests to which you wish to apply.

Note type Syntax
Whole :w
Dotted Whole :wd
Half :h
Dotted Half :hd
Quarter :q
Dotted Quarter :qd
Eighth :8
Dotted Eighth :8d
Sixteenth :16
Sixteenth :16d
For example

tabstave notation = true time = 4/4
notes :8 3/1 4/3 :q ## E/4 ##

tabstave notation = true time=4/4 notes :8 3/1 4/3 :q ## E/4 ##

Triplets

To transform a group of notes to triplets, the ^3^ syntax can be used AFTER the grouping of notes.

For example

tabstave notation = true time = 4/4
notes :8 3/1 4/3 4/6 ^3^ :q ## E/4 ##

options space = 30 tabstave notation = true time=4/4 notes :8 3/1 4/3 4/6 ^3^ :q ## E/4 ##

Chords

Chords can be made by grouping notes together using parentheses () on either end of the chord and separating the notes within the chord with a period (.).

For example

tabstave
notes (3/1.4/3.4/6)

tabstave notes (3/1.4/3.4/6)

Barlines and repeats

Barline type Syntax
Double Bar =||
Repeat Begin =|:
Repeat End =:|
Double Repeat =::
End Bar =|=

Ties, bends, and vibrato

To tie two notes together, use the a lowercase t in between the two notes. Adding vibrato, is as easy as appending the fret number or note name with a lowercase v (or uppercase V for strong vibrato). To bend from one note to another, use a lowercase b in between the two notes.

For example

tabstave notation = true
notes 3v/1 4/3t4/3b5/3

tabstave notation = true notes 3v/1 4/3t4/3b5/3

Hammer-ons, pull-offs, and slides

Hammer-ons, pull-offs, and slides are all written using the same type of syntax as bends. Between the two notes use a lowercase h for a hammer-on, a lowercase p for a pull-off, and a lowercase s for a slide.

For example

tabstave notation = true
notes 1/1p3/1 1/1h3/1 1/1s3/1

tabstave notation = true notes 1/1h3/1 1/1p3/1 1/1s3/1

Annotations, lyrics, and text

VexTab is very flexible in its ablity to display text. It can appear above the staff, below the staff, in different sizes, and in correspondance with specific notes (like lyrics).

Let's start with labeling text that may appear above the staff. This is achieved using the text keyword, immediately followed by the text that should be displayed.

For example

tabstave
text Introduction
notes (0/1.2/2.2/3.2/4.0/5) (0/1.0/2.1/3.2/4.2/5.0/6)

options space = 30 tabstave text Introduction notes (0/1.2/2.2/3.2/4.0/5) (0/1.0/2.1/3.2/4.2/5.0/6)

Now, to add additional text associated with each note or chord, simply append that note with the text wrapped in a dollar sign ($)

For example

tabstave
text Introduction
notes (0/1.2/2.2/3.2/4.0/5) $Lyric A$ (0/1.0/2.1/3.2/4.2/5.0/6) $Lyric B$

options space = 30 tabstave text Introduction notes (0/1.2/2.2/3.2/4.0/5) $Lyric A$ (0/1.0/2.1/3.2/4.2/5.0/6) $Lyric B$

Sometimes it's helpful to add additional text above each note or chord (or change the text's style). Using modifiers, we can control the text's position, size, and style. Here is a list of modifiers and what they do.

Effect Syntax
Place proceeding text on top of the note/chord. $.top.$
Place proceeding text below the note/chord. $.bottom.$
Use a large, bold style $.big.$
Use a medium style $.medium.$
Use an italic style $.italic.$
For example

tabstave
text Introduction
notes (0/1.2/2.2/3.2/4.0/5) $Lyric A$$.top.$$.big.A$ (0/1.0/2.1/3.2/4.2/5.0/6) $.bottom.$$Lyric B$$.top.$$.big.E$

options space = 30 tabstave text Introduction notes (0/1.2/2.2/3.2/4.0/5) $Lyric A$$.top.$$.big.A$ (0/1.0/2.1/3.2/4.2/5.0/6) $.bottom.$$Lyric B$$.top.$$.big.E$

Spacing and formatting

Using the options keyword, you can specify specific formatting options for your tabstave.

For example

options space = 60 stave-distance = 40
tabstave
text Introduction
notes (0/1.2/2.2/3.2/4.0/5) $Lyric A$$.top.$$.big.A$ (0/1.0/2.1/3.2/4.2/5.0/6) $.bottom.$$Lyric B$$.top.$$.big.E$

options space = 60 stave-distance = 40 tabstave notation = true text Introduction notes (0/1.2/2.2/3.2/4.0/5) $Lyric A$$.top.$$.big.A$ (0/1.0/2.1/3.2/4.2/5.0/6) $.bottom.$$Lyric B$$.top.$$.big.E$

This will add 60 extra pixels of space before the tabstave and adds 40 pixels of space between the tabstave and the standard notation staff. This is useful when you have annotations that could potentially be obfuscated by notation.

Tab Lab sets tabs free

Music on Tab Lab is available for everyone to view. We claim no ownership of any of the songs posted on this site, and expect our users to only post their original compositions, or interpretations of existing songs for educational purposes. Learn more about ownership of music.

Signing up for an account gives you access to create music, edit existing music, and track a song's history on Tab Lab from the time it was created through all of it the edits made to date.