Increased Ram Usage on android device <p>I run the following code to start a service:</p> <pre><code>public class MainActivity extends Activity { @Override protected void onCreate(Bundle savedInstanceState){ super.onCreate(savedInstanceState); setContentView(R.layout.activity_main); Intent intent = new Intent(this, CreatingService.class); startService(intent); //finish(); } } </code></pre> <p>This initially takes 13-14 MB of memory when seen in the task manager. When i go back to home screen and kill the activity (swiping off from recent list) the service gets recreated(<code>START_STICKY</code>) and it takes around 3-4 MB of memory from then on. Also if the <code>finish()</code> was not commented off in the above code it would take 3-4 MB again. But I cannot do this.</p> <p>Can anyone explain what exactly is happening and a workaround for this?</p>