Add only one input filter to a textarea using form api I have created a custom form, in which I have one textarea field with a wysiwyg.
Here is the code

$form['text'] = array(
    '#type' =&gt; 'text_format',
    '#default_value' =&gt; variable_get('text'),
    '#title' =&gt; t('text'),
    '#format' =&gt; NULL,
  );
  return system_settings_form($form);


So it returns me a textarea field with a format dropdown. Which I don't required. I need only to use the filtered_html and the format dropdown should not appear.
There are several  way to  achieve this, you can use the Hide Formats module: 


  Hide Formats allows you to collapse the "text format" or "input
  format" dropdowns to clean up the UI.


or Better Formats module:


  Better formats is a module to add more flexibility to Drupal's core input format system. Features 8.x &amp; 7.x (needs more testing for a stable release)
  
  
  Set allowed text formats per field. 
  Set default order of text formats per field. 
  Hide format tips per role. Hide more format tips link per role. 
  Hide format selection per role per entity.
  Currently only works on Field API fields on fieldable entities implementing core style text processing. The good thing is that is
  most things in core and contrib.
  


Or, use the FormAPI to disable it with something like:

// hook_form_alter function
function CUSTOM_MODULE_form_alter(&amp;$form, &amp;$form_state, $form_id) {
    // We want this on a specific node type
    if ($form_id == 'NODE_TYPE_node_form') {
        $form['#after_build'][] = 'CUSTOM_MODULE_NODE_TYPE_node_form_after_build';
    }
}

// afterbuild function
function CUSTOM_MODULE_NODE_TYPE_node_form_after_build($form) {
    // We want this on a specific field
    $form['YOUR_FIELD']['und']['0']['format']['#access'] = FALSE;
    return $form;
}


Also you can try this (I didn't test it but it may work):

$form['text'] = array(
    '#type' =&gt; 'text_format',
    '#default_value' =&gt; variable_get('text'),
    '#title' =&gt; t('text'),
    '#format' =&gt; "full_html",
    'format'=&gt;array('#access'=&gt; false),
  );