A unified finite-element approach to phase transformation (PT), twinning and fracture in elastoplastic materials both at small and finite strains is developed. The applicability of the approach is illustrated by numerical solutions of a number of two-dimensional elastoplastic boundary-value problems, in particular, layer by layer PT progress in a cylindrical specimen, adiabatic strain-induced PT at shear-band intersection and in a spherical particle imbedded in a cylindrical specimen, appearance and growth of a temperature-induced martensitic plate in austenitic matrix, furthermore the appearance of a single twin in an elastoplastic matrix under applied shear stress or displacement, fracture in a sample with an edge notch and an interaction between PT and fracture in the same sample. Both time independent and time dependent kinetics are considered. For time independent kinetics, in order to overcome nonuniqueness of solution of boundary-value problems due to competition between phase transition and plasticity and/or fracture, the global phase transition and fracture criteria based on stability analysis are applied. The solutions obtained give insight into various effects, in particular the very complex and nontrivial strain field variations and their influence on the driving force for structural changes, the peculiarity of interaction between phase transformation, twinning, fracture and plasticity, effect of strain hardening and adiabatic heating, formation of a discrete microstructure at phase transition and fracture (in particular, void nucleation ahead of the crack tip rather than continuous crack propagation). Some of the numerical results for the driving force are approximated analytically and applied to the analytical determination of the geometry of phase transformation and fracture zone based on the corresponding extremum principle.