How do I get a field translated in Drupal 8 I have a multilingual site in Drupal 8, and several node, some translated and others not.
As I can programmatically get the translated field or by default they give it back from the original language.

I got this:

$service_entities = entity_load_multiple_by_properties('node', array('type' =&gt; 'service'));

$services = [];
foreach ($service_entities as $entity) {
  $services[] = [
    'title' =&gt; $entity-&gt;title-&gt;value,
  ];
}


This code work fine, but when the title is translated Drupal give back in the default language in which it was created.
You can get a specific translation with $translation = $entity-&gt;getTranslation('de'), then you can use $translation exactly the same as $entity.

Usually, you don't want to get a specific translation, but the best translation that is available for the current language, for that, use getTranslationFromContext():

 $translation = \Drupal::service('entity.repository')-&gt;getTranslationFromCon‌​text($entity);