Topological band theory predicts that a topological electronic phase transition between two insulators must proceed via closure of the electronic gap. Here, we use this transition to circumvent the instability of metallic phases in π-conjugated one-dimensional (1D) polymers. By means of density functional theory, tight-binding and GW calculations, we predict polymers near the topological transition from a trivial to a non-trivial quantum phase. We then use on-surface synthesis with custom-designed precursors to make polymers consisting of 1D linearly bridged acene moieties, which feature narrow bandgaps and in-gap zero-energy edge states when in the topologically non-trivial phase close to the topological transition point. We also reveal the fundamental connection between topological classes and resonant forms of 1D π-conjugated polymers.