Make sure all images are of the same data type.
Make sure all images have the same number of bands.
Make sure all images have the same band names.
Here is a reproducible conceptual example:
Code Editor script
// Import a Landsat 8 image and calculate NDVI.
var img = ee.Image('LANDSAT/LC08/C01/T1_SR/LC08_038029_20190712');
var ndvi = img....
Have a look at the dissolve tool. It dissolves/merges all features of a layer into a single multi-feature, or dissolves based on an attribute, e.g. the name of the rivers (no need for 50 separate layers next time).
As with most tools, you may start batch editing at the bottom left. When filling in the layers into the batch dialogue, make sure to select all ...