Method for configuring a wireless network, wherein the wireless network comprises a network node ( 105 k) and a first network device ( 110 i) under coverage of the network node ( 105 k), the network node ( 105 k) acting as serving network node for the first network device, and the first network device being arranged for transmitting first data to the network node ( 105 k) over a first radio link, wherein the method comprises: determining the presence of a second network device ( 110 i) under coverage of said network node ( 105 k), the second network device being arranged for transmitting second data to a respective serving network node over a second radio link, determining ( 210, 310) a radio quality of the first radio link, determining ( 210, 310) a radio quality of the second radio link, determining ( 210, 310) a radio quality of a third radio link between the second network device and the first network device, and if the radio quality of the third radio link is higher than the radio quality of the second radio link, configuring the second network device to transmit the second data to the first network device over the third radio link and the first network device to retransmit, over the first radio link, said second data to the network node, wherein the wireless network supports first synchronization signals and a first physical random access channel for establishing a direct connection between the first network device and the network node ( 105 k) and between the second network device and the respective serving network node ( 105 k), and second synchronization signals and a second physical random access channel for establishing a direct connection between the first network device and the second network device, and wherein said configuring the second network device to transmit the second data to the first network device over the third radio link and the first network device to retransmit, over the first radio link, said second data to the network node is carried out if the first network device supports at least transmission of the second synchronization signals and reception on the second physical random access channel, and the second network device supports at least transmission on the first physical random access channel and on the second physical random access channel and reception of the second synchronization signals. determining the presence of a second network device ( 110 i) under coverage of said network node ( 105 k), the second network device being arranged for transmitting second data to a respective serving network node over a second radio link, determining ( 210, 310) a radio quality of the first radio link, determining ( 210, 310) a radio quality of the second radio link, determining ( 210, 310) a radio quality of a third radio link between the second network device and the first network device, and if the radio quality of the third radio link is higher than the radio quality of the second radio link, configuring the second network device to transmit the second data to the first network device over the third radio link and the first network device to retransmit, over the first radio link, said second data to the network node, wherein the wireless network supports first synchronization signals and a first physical random access channel for establishing a direct connection between the first network device and the network node ( 105 k) and between the second network device and the respective serving network node ( 105 k), and second synchronization signals and a second physical random access channel for establishing a direct connection between the first network device and the second network device, and wherein said configuring the second network device to transmit the second data to the first network device over the third radio link and the first network device to retransmit, over the first radio link, said second data to the network node is carried out if the first network device supports at least transmission of the second synchronization signals and reception on the second physical random access channel, and the second network device supports at least transmission on the first physical random access channel and on the second physical random access channel and reception of the second synchronization signals.