Spielberg used a lot of horror coded cinematography on E.T. During the film it flip flops a little between horror and family joyful. So much that in theory it shouldn't work. But when you are dealing with an extraterrestrial being or being manhandled by government scientists and military it is hard not to feel scared, and he conveyed that by showing that for a small child it would be absolutely terrifying. The 80s has a lot of films like this, where marketing and production were confused about whether they wanted these movies to be aimed at children or not. This gave us Gremlins, Terminator, Robocop and others that combined adult jokes, extreme gore and violence, cynic satire, but also toys tie ins, family fun sanitized trailers and marketing, and toy selling TV cartoons. If anything, E.T. is the tamest of the lot and is definitely, decidedly aimed at family audiences. I blame cocaine.
ADD: Just remembered all the sex innuendos and mortgage jokes in Ghostbusters.
Recently watched this with my kids after not seeing it since being a kid myself. My pet theory is that it's about coping with the death of a grandparent. When the scientists take E.T. away and hook him up to all the machines, it's like the experience of seeing grandma or grandpa in intensive care with tubes, ventilators, etc. We see things through the kid's eyes and there is a vague sense that the scientists are supposed to be trying to keep E.T. alive, but it looks like they are killing him.
In the end, the beloved companion E.T. goes up into the sky but says he will always be with Elliot in a sense (my memories of this part are pretty vague, but I think there was some message along these lines). Maybe this is just my personal experience, but it really brought back memories of going to see my grandparents in hospitals that were kind of threatening to me as a kid, and the idea that your relative is up in heaven now.