Cellulose nanofibrils can be utilized as a building block in novel material concepts. One area of particular interest is formation of hydrogels for use in medical applications such as drug delivery and tissue engineering. Compared to bacterial cellulose, which is presently used for some medical applications but is produced through a somewhat inefficient process, cellulose nanofibrils from wood can be produced effectively and in large quantities. Cellulose nanofibrils are nano-scaled fibres with high aspect ratio and strong interactions with water. In order to produce stable macroscopic structures which perform adequately in humid conditions, the nanofibrils must be cross-linked in a controlled way. Several properties are important for a successful utilization of hydrogels for biomedical applications, such as degradation, bio-adhesion, bioactivity, transport through the network and mechanical properties. In the present work focus is set on the mechanical and viscoelastic properties of hydrogels. Hydrogels of oxidized cellulose nanofibrils were formed by crosslinking the nanofibrils through the formation of covalent bonds between the crosslinking molecules and oxidized sites at the nanofibril surfaces. The elastic moduli of the hydrogels were controlled by varying the concentration and the length of the crosslinking molecules. Results from cytotoxicity studies of cellulose nanofibrils will be shown.