We study boundary value problems for bounded uniform domains in R n , n ≥ 2, with non-Lipschitz (and possibly fractal) boundaries. We prove Poincaré inequalities with trace terms and uniform constants for uniform (ε, ∞)-domains within bounded common confinements. We then introduce generalized Dirichlet, Robin and Neumann problems for Poisson type equations and prove the Mosco convergence of the associated energy functionals along sequences of suitably converging domains. This implies a stability result for weak solutions, and this also implies the norm convergence of the associated resolvents and the convergence of the corresponding eigenvalues and eigenfunctions. Based on our earlier work, we prove compactness results for parametrized classes of admissible domains, energy functionals and weak solutions. Using these results, we can verify the existence of optimal shapes in these classes.