Everything from {% block NAME %} till {% endblock [NAME] %} is treated as a block with the name NAME. In another template, which contains an {% extends "abovetemplate" %}, the block NAME can be overwritten.

The previous content of the block can be used in that block via the variable {{ block.super }}

If no new block with the same name is defined, the default text is used.

If no extend is used, the {% block %} tags will just return their content.

Of course all variables in a block will work just as they would outside, even if the block is defined in a different file alltogether.