Going to the pool or a friend’s house during the summer months is common with children. There is no need to wear shoes between home and these destinations, especially when they are promptly removed upon arrival.
Some bicycle foot pedals may be uncomfortable or slightly harder to grip without shoes, but different versions may be purchased that are nicer on bare feet. As a child becomes more familiar with barefooting, it likely will not be an issue. A helmet is always a good idea when riding either of these devices for head safety in case of falling or a collision.
For young children, learning to ride a bike while barefoot can be easier than with shoes. Bare feet can curl and grip pedals more easily and therefore give better control of the device. As with any part of starting to go barefoot, you need to just do it!