The present invention relates to 5-hydroxy-indole-3-carboxylate derivatives of formula I, or racemic mixture or optical isomers or pharmaceutically acceptable salts and/or hydrates thereof,
wherein: substituents R1, R2, Z, X and Y are as defined in the description. The compounds of formula I can be useful for preparation of medicament for treatment and/or prophylaxis of virus infections, especially for preparation of medicament for anti-HBV (Hepatitis B virus) and anti-HIV (Human immunodeficiency virus).