Conformational changes of biological macromolecules when binding with ligands have long been observed and remain a challenge for automated docking methods. Here we present a novel protein-ligand docking software called FLIPDock (Flexible LIgand-Protein Docking) allowing the automated docking of flexible ligand molecules into active sites of flexible receptor molecules. In FLIPDock, conformational spaces of molecules are encoded using a data structure that we have developed recently called the Flexibility Tree (FT). While the FT can represent fully flexible ligands, it was initially designed as a hierarchical and multiresolution data structure for the selective encoding of conformational subspaces of large biological macromolecules. These conformational subspaces can be built to span a range of conformations important for the biological activity of a protein. A variety of motions can be combined, ranging from domains moving as rigid bodies or backbone atoms undergoing normal mode-based deformations, to side chains assuming rotameric conformations. In addition, these conformational subspaces are parameterized by a small number of variables which can be searched during the docking process, thus effectively modeling the conformational changes in a flexible receptor. FLIPDock searches the variables using genetic algorithm-based search techniques and evaluates putative docking complexes with a scoring function based on the AutoDock3.05 force-field. In this paper, we describe the concepts behind FLIPDock and the overall architecture of the program. We demonstrate FLIPDock's ability to solve docking problems in which the assumption of a rigid receptor previously prevented the successful docking of known ligands. In particular, we repeat an earlier cross docking experiment and demonstrate an increased success rate of 93.5%, compared to original 72% success rate achieved by AutoDock over the 400 cross-docking calculations. We also demonstrate FLIPDock's ability to handle conformational changes involving backbone motion by docking balanol to an adenosine-binding pocket of protein kinase A.